private void SetupProvider() { try { if (EditorManager.Providers[providerName] != null) { editorProvider = EditorManager.Providers[providerName]; } else { editorProvider = EditorManager.Providers[failsafeProviderName]; } editor = editorProvider.GetEditor(); editor.ControlID = this.ID + "innerEditor"; editor.SiteRoot = Page.ResolveUrl("~/"); editor.ScriptBaseUrl = Page.ResolveUrl(scriptBaseUrl); this.Controls.Clear(); this.Controls.Add(editor.GetEditorControl()); } catch (TypeInitializationException ex) { log.Error(ex); } }
private static void Initialize() { //try //{ EditorConfiguration editorConfig = EditorConfiguration.GetConfig(); if ( (editorConfig.DefaultProvider == null) || (editorConfig.Providers == null) || (editorConfig.Providers.Count < 1) ) { throw new ProviderException("You must specify a valid default provider."); } providerCollection = new EditorProviderCollection(); ProvidersHelper.InstantiateProviders( editorConfig.Providers, providerCollection, typeof(EditorProvider)); providerCollection.SetReadOnly(); defaultProvider = providerCollection[editorConfig.DefaultProvider]; //} //catch (Exception ex) //{ // initializationException = ex; // isInitialized = true; // throw ex; //} //isInitialized = true; }
public void CopyTo(EditorProvider[] array, int index) { base.CopyTo(array, index); }