set screen.index.
This commit is contained in:
parent
86fb0582cc
commit
7351c8a716
|
@ -33,7 +33,7 @@ function Node(options) {
|
|||
this.children = [];
|
||||
this.$ = this._ = this.data = {};
|
||||
this.uid = Node.uid++;
|
||||
this.index = -1;
|
||||
this.index = this.index != null ? this.index : -1;
|
||||
|
||||
if (this.type !== 'screen') {
|
||||
this.detached = true;
|
||||
|
|
|
@ -200,6 +200,7 @@ Screen.bind = function(screen) {
|
|||
|
||||
if (!~Screen.instances.indexOf(screen)) {
|
||||
Screen.instances.push(screen);
|
||||
screen.index = Screen.total;
|
||||
Screen.total++;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue