public void EndUpdate() { IAttachViewRoot attachedViewRoot; this.IsDelaying = false; List <CrossDocumentUpdateContext.ContextInfo> contextInfos = this.contexts; this.contexts = null; for (int i = contextInfos.Count - 1; i >= 0; i--) { CrossDocumentUpdateContext.ContextInfo item = contextInfos[i]; if (item.DelayedNodes != null) { item.Context.ViewNodeManager.UpdateDelayedNodes(item.DelayedNodes); } } for (int j = contextInfos.Count - 1; j >= 0; j--) { CrossDocumentUpdateContext.ContextInfo contextInfo = contextInfos[j]; InstanceBuilderContextBase context = contextInfo.Context as InstanceBuilderContextBase; if (context != null) { attachedViewRoot = context.AttachedViewRoot; } else { attachedViewRoot = null; } contextInfo.Context.ViewNodeManager.UpdateReferences(attachedViewRoot, false); } }
public ChangeContainerRootToken(InstanceBuilderContextBase context, ViewNode newRoot, INameScope newNameScope) { this.context = context; this.containerRoot = context.containerRoot; this.containerNameScope = context.nameScope; context.ChangeContainerRootInternal(newRoot, newNameScope); }
private void Dispose(bool disposing) { if (disposing) { this.context.AllowPostponingResourceEvaluation = this.oldAllow; this.context = null; } }
public void Dispose() { if (this.context != null) { this.context.crossDocumentUpdateContext = this.originalCrossDocumentUpdateContext; this.context = null; } GC.SuppressFinalize(this); }
public void Dispose() { if (this.context != null) { this.context.resourceDictionaryHost = this.originalHost; this.context = null; } GC.SuppressFinalize(this); }
public SetSerializationContextToken(InstanceBuilderContextBase context, ISerializationContext serializationContext) { this.context = context; this.serializationContext = context.serializationContext; context.ChangeSerializationContextInternal(serializationContext); }
public InstantiatingUserControlPreviewToken(InstanceBuilderContextBase context, string xamlSourcePath) { this.context = context; this.xamlSourcePath = xamlSourcePath; context.currentlyInstantiatingUserControlPreviews.Add(xamlSourcePath); }
public ForceUseShadowPropertiesToken(InstanceBuilderContextBase context, bool useShadowProperties) { this.context = context; this.useShadowProperties = context.useShadowProperties; this.context.ForceUseShadowPropertiesInternal(useShadowProperties); }
public ForceRegistrationOfInstantiatedElementsToken(InstanceBuilderContextBase context, bool shouldRegisterInstantiatedElements) { this.context = context; this.shouldRegisterInstantiatedElements = context.shouldRegisterInstantiatedElements; this.context.ForceRegistrationOfInstantiatedElementsInternal(shouldRegisterInstantiatedElements); }
public ForcePostponedResourceEvaluationToken(InstanceBuilderContextBase context) { this.context = context; this.oldAllow = this.context.AllowPostponingResourceEvaluation; this.context.AllowPostponingResourceEvaluation = false; }
public ForceAllowIncrementalTemplateUpdatesToken(InstanceBuilderContextBase context, bool allow) { this.context = context; this.oldAllow = this.context.AllowIncrementalTemplateUpdates; this.context.AllowIncrementalTemplateUpdates = allow; }
public ChangeCrossDocumentUpdateContextToken(InstanceBuilderContextBase context, ICrossDocumentUpdateContext crossDocumentUpdateContext) { this.context = context; this.originalCrossDocumentUpdateContext = this.context.crossDocumentUpdateContext; this.context.crossDocumentUpdateContext = crossDocumentUpdateContext; }
public ChangeApplicationResourcesHostToken(InstanceBuilderContextBase context, IResourceDictionaryHost host) { this.context = context; this.originalHost = this.context.resourceDictionaryHost; this.context.resourceDictionaryHost = host; }
public static void TransferViewRootResolver(InstanceBuilderContextBase source, InstanceBuilderContextBase target) { target.viewRootResolver = source.viewRootResolver; }