void OnDeleteAnnotationCommandCanExecute(object sender, CanExecuteRoutedEventArgs e) { if (EditingContextUtilities.GetSingleSelectedModelItem(this.Context) == this.ModelItem) { ContextMenuUtilities.OnDeleteAnnotationCommandCanExecute(e, this.Context, this.FindSwitch()); } }
void OnEditAnnotationCommandCanExecute(object sender, CanExecuteRoutedEventArgs e) { if (EditingContextUtilities.GetSingleSelectedModelItem(this.Context) == this.ModelItem) { // call the same method as delete annotation command ContextMenuUtilities.OnDeleteAnnotationCommandCanExecute(e, this.Context, this.FindTryCatch()); } }
void OnDeleteAnnotationCommandExecuted(object sender, ExecutedRoutedEventArgs e) { ContextMenuUtilities.OnDeleteAnnotationCommandExecuted(e, this.FindSwitch()); }
void OnEditAnnotationCommandExecuted(object sender, ExecutedRoutedEventArgs e) { ContextMenuUtilities.OnEditAnnotationCommandExecuted(e, this.FindTryCatch()); }