tabs navbar wip

This commit is contained in:
Adam Bradley
2015-06-08 17:16:22 -05:00
parent 9df956e865
commit a94186d970
4 changed files with 52 additions and 32 deletions

View File

@ -11,7 +11,7 @@ import {bind} from 'angular2/di';
import {NavController} from './nav-controller';
import {NavItem, NavParams} from './nav-item';
import {Pane, NavBarSection} from './pane';
import {Pane, NavBarContainer} from './pane';
import {Transition} from '../../transitions/transition';
import {ClickBlock} from '../../util/click-block';
import * as util from 'ionic/util';
@ -80,7 +80,7 @@ export class NavBase {
// decide which sections should be added to this Pane, ie: nav bars, tab bars, etc.
// add only the sections it needs
if (itemStructure.navbar) {
sectionsToAdd.push(NavBarSection);
sectionsToAdd.push(NavBarContainer);
}
// add the sections which this type of Pane requires
@ -476,6 +476,18 @@ export class NavBase {
return this.domElement;
}
navbarViewContainer(nbContainer) {
if (nbContainer) {
this._nbContainer = nbContainer;
}
if (this._nbContainer) {
return this._nbContainer;
}
if (this.parent) {
return this.parent.navbarViewContainer();
}
}
add(item) {
item.id = this.id + '' + (++this.childIds);
this.items.push(item);