removed circular deps so tests run on node
This commit is contained in:
@ -1,11 +1,11 @@
|
||||
import {int, isBlank, BaseException} from 'angular2/src/facade/lang';
|
||||
import {ProtoElementInjector} from './element_injector';
|
||||
import * as eiModule from './element_injector';
|
||||
import {DirectiveMetadata} from './directive_metadata';
|
||||
import {List, StringMap} from 'angular2/src/facade/collection';
|
||||
import {ProtoView} from './view';
|
||||
|
||||
export class ElementBinder {
|
||||
protoElementInjector:ProtoElementInjector;
|
||||
protoElementInjector:eiModule.ProtoElementInjector;
|
||||
componentDirective:DirectiveMetadata;
|
||||
viewportDirective:DirectiveMetadata;
|
||||
textNodeIndices:List<int>;
|
||||
@ -18,7 +18,7 @@ export class ElementBinder {
|
||||
distanceToParent:int;
|
||||
constructor(
|
||||
index:int, parent:ElementBinder, distanceToParent: int,
|
||||
protoElementInjector: ProtoElementInjector, componentDirective:DirectiveMetadata,
|
||||
protoElementInjector: eiModule.ProtoElementInjector, componentDirective:DirectiveMetadata,
|
||||
viewportDirective:DirectiveMetadata) {
|
||||
if (isBlank(index)) {
|
||||
throw new BaseException('null index not allowed.');
|
||||
|
@ -9,7 +9,7 @@ import {ViewContainer} from 'angular2/src/core/compiler/view_container';
|
||||
import {NgElement} from 'angular2/src/core/dom/element';
|
||||
import {Directive, onChange, onDestroy} from 'angular2/src/core/annotations/annotations';
|
||||
import {BindingPropagationConfig} from 'angular2/src/core/compiler/binding_propagation_config';
|
||||
import {PrivateComponentLocation} from 'angular2/src/core/compiler/private_component_location';
|
||||
import * as pclModule from 'angular2/src/core/compiler/private_component_location';
|
||||
import {reflector} from 'angular2/src/reflection/reflection';
|
||||
|
||||
var _MAX_DIRECTIVE_CONSTRUCTION_COUNTER = 10;
|
||||
@ -33,7 +33,7 @@ class StaticKeys {
|
||||
this.ngElementId = Key.get(NgElement).id;
|
||||
this.viewContainerId = Key.get(ViewContainer).id;
|
||||
this.bindingPropagationConfigId = Key.get(BindingPropagationConfig).id;
|
||||
this.privateComponentLocationId = Key.get(PrivateComponentLocation).id;
|
||||
this.privateComponentLocationId = Key.get(pclModule.PrivateComponentLocation).id;
|
||||
}
|
||||
|
||||
static instance() {
|
||||
@ -603,7 +603,7 @@ export class ElementInjector extends TreeNode {
|
||||
if (keyId === staticKeys.bindingPropagationConfigId) return this._preBuiltObjects.bindingPropagationConfig;
|
||||
|
||||
if (keyId === staticKeys.privateComponentLocationId) {
|
||||
return new PrivateComponentLocation(this, this._preBuiltObjects.element, this._preBuiltObjects.view);
|
||||
return new pclModule.PrivateComponentLocation(this, this._preBuiltObjects.element, this._preBuiltObjects.view);
|
||||
}
|
||||
|
||||
//TODO add other objects as needed
|
||||
|
@ -1,7 +1,7 @@
|
||||
import {Directive} from 'angular2/src/core/annotations/annotations'
|
||||
import {NgElement} from 'angular2/src/core/dom/element';
|
||||
import {ElementInjector} from './element_injector';
|
||||
import {ProtoView, View} from './view';
|
||||
import * as viewModule from './view';
|
||||
import * as eiModule from './element_injector';
|
||||
import {ShadowDomStrategy} from './shadow_dom_strategy';
|
||||
import {EventManager} from 'angular2/src/core/events/event_manager';
|
||||
import {ListWrapper} from 'angular2/src/facade/collection';
|
||||
@ -9,17 +9,17 @@ import {Type} from 'angular2/src/facade/lang';
|
||||
|
||||
|
||||
export class PrivateComponentLocation {
|
||||
_elementInjector:ElementInjector;
|
||||
_elementInjector:eiModule.ElementInjector;
|
||||
_elt:NgElement;
|
||||
_view:View;
|
||||
_view:viewModule.View;
|
||||
|
||||
constructor(elementInjector:ElementInjector, elt:NgElement, view:View){
|
||||
constructor(elementInjector:eiModule.ElementInjector, elt:NgElement, view:viewModule.View){
|
||||
this._elementInjector = elementInjector;
|
||||
this._elt = elt;
|
||||
this._view = view;
|
||||
}
|
||||
|
||||
createComponent(type:Type, annotation:Directive, componentProtoView:ProtoView,
|
||||
createComponent(type:Type, annotation:Directive, componentProtoView:viewModule.ProtoView,
|
||||
eventManager:EventManager, shadowDomStrategy:ShadowDomStrategy) {
|
||||
var context = this._elementInjector.createPrivateComponent(type, annotation);
|
||||
|
||||
|
Reference in New Issue
Block a user