use injector instead of passing params

This commit is contained in:
Adam Bradley
2015-06-27 14:42:09 -05:00
parent edbcf9f834
commit f21802ba87
4 changed files with 6 additions and 20 deletions

View File

@ -36,15 +36,13 @@ export class Tab extends ViewController {
constructor(
@Parent() tabs: Tabs,
compiler: Compiler,
elementRef: ElementRef,
loader: DynamicComponentLoader,
injector: Injector
) {
// A Tab is both a container of many views, and is a view itself.
// A Tab is one ViewItem within it's parent Tabs (which extends ViewController)
// A Tab is a ViewController for its child ViewItems
super(tabs, compiler, elementRef, loader, injector);
super(tabs, injector);
this.tabs = tabs;
this.childNavbar(true);

View File

@ -46,12 +46,9 @@ export class Tabs extends ViewController {
constructor(
@Optional() parentViewCtrl: ViewController,
@Optional() viewItem: ViewItem,
compiler: Compiler,
elementRef: ElementRef,
loader: DynamicComponentLoader,
injector: Injector
) {
super(parentViewCtrl, compiler, elementRef, loader, injector);
super(parentViewCtrl, injector);
// Tabs may also be an actual ViewItem which was navigated to
// if Tabs is static and not navigated to within a ViewController