zIndex views

This commit is contained in:
Adam Bradley
2015-07-17 16:16:03 -05:00
parent cb5fa23a80
commit 334fd7f891
4 changed files with 22 additions and 4 deletions

View File

@@ -511,6 +511,10 @@ export class ViewController extends Ion {
util.array.remove(this.items, itemOrIndex);
}
indexOf(item) {
return this.items.indexOf(item);
}
length() {
return this.items.length;
}

View File

@@ -170,6 +170,10 @@ export class ViewItem {
this.instance._viewItem = this;
}
get index() {
return (this.viewCtrl ? this.viewCtrl.indexOf(this) : -1);
}
destroy() {
for (let i = 0; i < this.disposals.length; i++) {
this.disposals[i]();