internal override void ApplyBeforeInsertionDefaultsToElements(IList <SceneNode> nodes, SceneNode rootNode, DefaultTypeInstantiator.SceneElementNamingCallback callback) { if (this.provider.ContentProvider != null) { this.provider.ContentProvider.EnsureLinked(this.ViewModel); } base.ApplyBeforeInsertionDefaultsToElements(nodes, rootNode, callback); }
internal virtual void ApplyBeforeInsertionDefaultsToElements(IList <SceneNode> nodes, SceneNode rootNode, DefaultTypeInstantiator.SceneElementNamingCallback callback) { foreach (SceneNode sceneNode in (IEnumerable <SceneNode>)nodes) { if (ProjectNeutralTypes.DockPanel.IsAssignableFrom((ITypeId)sceneNode.Type)) { sceneNode.SetValue(DockPanelElement.LastChildFillProperty, (object)false); } SceneElement sceneElement = sceneNode as SceneElement; if (sceneElement != null) { sceneElement.Name = callback(sceneElement); } } foreach (SceneNode node in (IEnumerable <SceneNode>)nodes) { StyleAsset relatedUserThemeAsset = this.GetRelatedUserThemeAsset(node, rootNode); if (relatedUserThemeAsset != null) { relatedUserThemeAsset.ApplyStyle(node); } } }