protected override BaseFrameworkElement CreateElementOnStartDrag()
        {
            bool       flag       = true;
            Asset      asset      = this.Asset;
            TypeAsset  typeAsset  = asset as TypeAsset;
            StyleAsset styleAsset = asset as StyleAsset;

            if (typeAsset != null && typeAsset.Type is IUnreferencedType)
            {
                flag = false;
            }
            else if (styleAsset != null)
            {
                UserThemeAssetProvider themeAssetProvider = styleAsset.Provider as UserThemeAssetProvider;
                if (themeAssetProvider != null && !themeAssetProvider.IsLocal)
                {
                    flag = false;
                }
            }
            if (flag && asset.CanCreateInstance(this.ActiveSceneInsertionPoint))
            {
                return(this.CreateInstance(Rect.Empty) as BaseFrameworkElement);
            }
            return((BaseFrameworkElement)null);
        }
 public UserThemeStyleAssetInstantiator(SceneView sceneView, UserThemeAssetProvider provider, UserThemeAssetProvider.UserThemeStyleAsset styleAsset)
     : base(sceneView, (StyleAssetProvider)provider, (StyleAsset)styleAsset)
 {
     this.provider = provider;
 }
 public UserThemeStyleAsset(UserThemeAssetProvider provider, ResourceModel resourceModel)
     : base((ResourceDictionaryAssetProvider)provider, resourceModel)
 {
     this.provider = provider;
 }