refactor(DomRootRenderer): allow registeredComponents access

Closes #6584
This commit is contained in:
gdi2290 2016-02-01 15:51:00 -08:00 committed by Misko Hevery
parent 6ce13b68fa
commit d4827caa08
1 changed files with 3 additions and 3 deletions

View File

@ -35,16 +35,16 @@ const TEMPLATE_COMMENT_TEXT = 'template bindings={}';
var TEMPLATE_BINDINGS_EXP = /^template bindings=(.*)$/g;
export abstract class DomRootRenderer implements RootRenderer {
private _registeredComponents: Map<string, DomRenderer> = new Map<string, DomRenderer>();
protected registeredComponents: Map<string, DomRenderer> = new Map<string, DomRenderer>();
constructor(public document: any, public eventManager: EventManager,
public sharedStylesHost: DomSharedStylesHost, public animate: AnimationBuilder) {}
renderComponent(componentProto: RenderComponentType): Renderer {
var renderer = this._registeredComponents.get(componentProto.id);
var renderer = this.registeredComponents.get(componentProto.id);
if (isBlank(renderer)) {
renderer = new DomRenderer(this, componentProto);
this._registeredComponents.set(componentProto.id, renderer);
this.registeredComponents.set(componentProto.id, renderer);
}
return renderer;
}