private static void OnBindingContentChanged(object sender, DependencyPropertyChangedEventArgs e) { WpfHtmlEditor editor = (WpfHtmlEditor)sender; editor.myBindingContent = (string)e.NewValue; editor.ContentHtml = editor.myBindingContent; }
private static void OnEditModeChanged(object sender, DependencyPropertyChangedEventArgs e) { WpfHtmlEditor editor = (WpfHtmlEditor)sender; if ((EditMode)e.NewValue == EditMode.Visual) { editor.SetVisualMode(); } else { editor.SetSourceMode(); } }