1 instantiation of CommandManager
PresentationCore (1)
System\Windows\Input\Command\CommandManager.cs (1)
262
_commandManager = new
CommandManager
();
146 references to CommandManager
PresentationCore (38)
System\Windows\Generated\UIElement.cs (12)
793
EventManager.RegisterClassHandler(type,
CommandManager
.PreviewExecutedEvent, new ExecutedRoutedEventHandler(UIElement.OnPreviewExecutedThunk), false);
794
EventManager.RegisterClassHandler(type,
CommandManager
.ExecutedEvent, new ExecutedRoutedEventHandler(UIElement.OnExecutedThunk), false);
795
EventManager.RegisterClassHandler(type,
CommandManager
.PreviewCanExecuteEvent, new CanExecuteRoutedEventHandler(UIElement.OnPreviewCanExecuteThunk), false);
796
EventManager.RegisterClassHandler(type,
CommandManager
.CanExecuteEvent, new CanExecuteRoutedEventHandler(UIElement.OnCanExecuteThunk), false);
857
CommandManager
.TranslateInput((IInputElement)sender, e);
1224
CommandManager
.TranslateInput((IInputElement)sender, e);
1954
CommandManager
.TranslateInput((IInputElement)sender, e);
2185
CommandManager
.OnExecuted(sender, e);
2193
CommandManager
.OnExecuted(sender, e);
2201
CommandManager
.OnCanExecute(sender, e);
2209
CommandManager
.OnCanExecute(sender, e);
2217
CommandManager
.OnCommandDevice(sender, e);
System\Windows\Input\Command\CanExecuteChangedEventManager.cs (1)
458
if (sender is
CommandManager
)
System\Windows\Input\Command\CommandBinding.cs (3)
131
if (e.RoutedEvent ==
CommandManager
.CanExecuteEvent)
165
RoutedEvent =
CommandManager
.CanExecuteEvent,
185
if (e.RoutedEvent ==
CommandManager
.ExecutedEvent)
System\Windows\Input\Command\CommandDevice.cs (1)
118
CommandManager
.InvalidateRequerySuggested();
System\Windows\Input\Command\CommandManager.cs (15)
51
typeof(
CommandManager
));
86
typeof(
CommandManager
));
121
typeof(
CommandManager
));
156
typeof(
CommandManager
));
246
CommandManager
.Current.RaiseRequerySuggested();
256
private static
CommandManager
Current
521
canExecuteArgs.RoutedEvent =
CommandManager
.CanExecuteEvent;
528
executedArgs.RoutedEvent =
CommandManager
.ExecutedEvent;
760
private static
CommandManager
_commandManager;
846
public static void AddHandler(
CommandManager
source, EventHandler handler)
857
public static void RemoveHandler(
CommandManager
source, EventHandler handler)
886
CommandManager
typedSource =
CommandManager
.Current;
895
CommandManager
typedSource =
CommandManager
.Current;
System\Windows\Input\Command\RoutedCommand.cs (6)
116
add {
CommandManager
.RequerySuggested += value; }
117
remove {
CommandManager
.RequerySuggested -= value; }
334
args.RoutedEvent =
CommandManager
.PreviewCanExecuteEvent;
338
args.RoutedEvent =
CommandManager
.CanExecuteEvent;
393
args.RoutedEvent =
CommandManager
.PreviewExecutedEvent;
418
args.RoutedEvent =
CommandManager
.ExecutedEvent;
PresentationFramework (87)
MS\Internal\AppModel\JournalNavigationScope.cs (1)
476
System.Windows.Input.
CommandManager
.InvalidateRequerySuggested();
MS\Internal\Commands\CommandHelpers.cs (2)
107
CommandManager
.RegisterClassCommandBinding(controlType, new CommandBinding(command, executedRoutedEventHandler, canExecuteRoutedEventHandler));
114
CommandManager
.RegisterClassInputBinding(controlType, new InputBinding(command, inputGestures[i]));
System\Windows\Annotations\AnnotationService.cs (18)
59
CommandManager
.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand));
61
CommandManager
.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand));
63
CommandManager
.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand));
65
CommandManager
.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand));
67
CommandManager
.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand));
69
CommandManager
.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand));
71
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand));
73
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand));
75
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand));
77
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand));
79
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand));
81
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand));
83
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand));
85
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand));
87
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand));
89
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand));
91
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand));
93
CommandManager
.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand));
System\Windows\Controls\DataGrid.cs (22)
60
CommandManager
.RegisterClassInputBinding(ownerType, new InputBinding(BeginEditCommand, new KeyGesture(Key.F2)));
61
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(BeginEditCommand, new ExecutedRoutedEventHandler(OnExecutedBeginEdit), new CanExecuteRoutedEventHandler(OnCanExecuteBeginEdit)));
63
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(CommitEditCommand, new ExecutedRoutedEventHandler(OnExecutedCommitEdit), new CanExecuteRoutedEventHandler(OnCanExecuteCommitEdit)));
65
CommandManager
.RegisterClassInputBinding(ownerType, new InputBinding(CancelEditCommand, new KeyGesture(Key.Escape)));
66
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(CancelEditCommand, new ExecutedRoutedEventHandler(OnExecutedCancelEdit), new CanExecuteRoutedEventHandler(OnCanExecuteCancelEdit)));
68
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(SelectAllCommand, new ExecutedRoutedEventHandler(OnExecutedSelectAll), new CanExecuteRoutedEventHandler(OnCanExecuteSelectAll)));
70
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(DeleteCommand, new ExecutedRoutedEventHandler(OnExecutedDelete), new CanExecuteRoutedEventHandler(OnCanExecuteDelete)));
73
CommandManager
.RegisterClassCommandBinding(typeof(DataGrid), new CommandBinding(ApplicationCommands.Copy, new ExecutedRoutedEventHandler(OnExecutedCopy), new CanExecuteRoutedEventHandler(OnCanExecuteCopy)));
2280
CommandManager
.InvalidateRequerySuggested();
2410
CommandManager
.InvalidateRequerySuggested();
2575
CommandManager
.InvalidateRequerySuggested();
2788
CommandManager
.InvalidateRequerySuggested();
3045
CommandManager
.InvalidateRequerySuggested();
3393
CommandManager
.InvalidateRequerySuggested();
3412
CommandManager
.InvalidateRequerySuggested();
3515
CommandManager
.InvalidateRequerySuggested();
3595
CommandManager
.InvalidateRequerySuggested();
3605
CommandManager
.InvalidateRequerySuggested();
4289
CommandManager
.InvalidateRequerySuggested();
4559
CommandManager
.InvalidateRequerySuggested();
5415
CommandManager
.InvalidateRequerySuggested();
8235
CommandManager
.InvalidateRequerySuggested();
System\Windows\Controls\DataGridCell.cs (1)
236
CommandManager
.InvalidateRequerySuggested();
System\Windows\Controls\DocumentViewer.cs (3)
1709
CommandManager
.RegisterClassInputBinding(typeof(DocumentViewer),
1719
CommandManager
.RegisterClassInputBinding(typeof(DocumentViewer),
1729
CommandManager
.RegisterClassInputBinding(typeof(DocumentViewer),
System\Windows\Controls\FlowDocumentReader.cs (8)
676
CommandManager
.InvalidateRequerySuggested();
1171
CommandManager
.AddPreviewCanExecuteHandler(_pageViewer, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1181
CommandManager
.AddPreviewCanExecuteHandler(_twoPageViewer, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1191
CommandManager
.AddPreviewCanExecuteHandler(_scrollViewer, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1249
CommandManager
.InvalidateRequerySuggested();
1718
CommandManager
.InvalidateRequerySuggested();
1730
CommandManager
.InvalidateRequerySuggested();
1743
CommandManager
.InvalidateRequerySuggested();
System\Windows\Controls\FlowDocumentScrollViewer.cs (5)
570
CommandManager
.InvalidateRequerySuggested();
579
CommandManager
.AddPreviewCanExecuteHandler(_contentHost, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1071
CommandManager
.RemovePreviewCanExecuteHandler(_contentHost, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1085
CommandManager
.InvalidateRequerySuggested();
1629
CommandManager
.InvalidateRequerySuggested();
System\Windows\Controls\MenuItem.cs (1)
617
CommandManager
.InvalidateRequerySuggested(); // Should post an idle queue item to update IsEnabled on commands
System\Windows\Controls\Primitives\DocumentViewerBase.cs (4)
594
CommandManager
.InvalidateRequerySuggested();
1269
CommandManager
.InvalidateRequerySuggested();
1443
CommandManager
.InvalidateRequerySuggested();
1620
CommandManager
.InvalidateRequerySuggested();
System\Windows\Controls\Primitives\Track.cs (2)
187
CommandManager
.InvalidateRequerySuggested(); // Should post an idle queue item to update IsEnabled on button
228
CommandManager
.InvalidateRequerySuggested(); // Should post an idle queue item to update IsEnabled on button
System\Windows\Controls\SinglePageViewer.cs (14)
678
CommandManager
.InvalidateRequerySuggested();
685
CommandManager
.AddPreviewCanExecuteHandler(this, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1106
CommandManager
.RemovePreviewCanExecuteHandler(this, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler));
1118
CommandManager
.InvalidateRequerySuggested();
1273
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.PreviousPage, new KeyGesture(Key.Left)));
1274
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.PreviousPage, new KeyGesture(Key.Up)));
1275
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.PreviousPage, new KeyGesture(Key.PageUp)));
1276
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.NextPage, new KeyGesture(Key.Right)));
1277
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.NextPage, new KeyGesture(Key.Down)));
1278
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.NextPage, new KeyGesture(Key.PageDown)));
1279
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.FirstPage, new KeyGesture(Key.Home)));
1280
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.FirstPage, new KeyGesture(Key.Home, ModifierKeys.Control)));
1281
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.LastPage, new KeyGesture(Key.End)));
1282
CommandManager
.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.LastPage, new KeyGesture(Key.End, ModifierKeys.Control)));
System\Windows\Navigation\NavigationWindow.cs (5)
174
CommandManager
.RegisterClassCommandBinding(
181
CommandManager
.RegisterClassCommandBinding(
188
CommandManager
.RegisterClassCommandBinding(
192
CommandManager
.RegisterClassCommandBinding(
199
CommandManager
.RegisterClassCommandBinding(
System\Windows\Window.cs (1)
3591
CommandManager
.RegisterClassCommandBinding(typeof(Window), binding);
PresentationUI (9)
InstallationError.xaml.cs (1)
24
CommandManager
.RegisterClassCommandBinding(typeof(InstallationErrorPage),
MS\Internal\Documents\DocumentApplicationDocumentViewer.cs (5)
335
CommandManager
.InvalidateRequerySuggested();
354
CommandManager
.InvalidateRequerySuggested();
392
CommandManager
.InvalidateRequerySuggested();
2133
CommandManager
.RegisterClassCommandBinding(typeof(DocumentApplicationDocumentViewer),
2141
CommandManager
.RegisterClassInputBinding(typeof(DocumentApplicationDocumentViewer),
TenFeetInstallationError.xaml.cs (1)
31
CommandManager
.RegisterClassCommandBinding(typeof(TenFeetInstallationError),
TenFeetInstallationProgress.xaml.cs (2)
32
CommandManager
.RegisterClassCommandBinding(typeof(TenFeetInstallationProgress),
37
CommandManager
.RegisterClassCommandBinding(typeof(TenFeetInstallationProgress),
System.Windows.Controls.Ribbon (12)
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (6)
107
CommandManager
.RegisterClassCommandBinding(ownerType,
109
CommandManager
.RegisterClassCommandBinding(ownerType,
111
CommandManager
.RegisterClassCommandBinding(ownerType,
113
CommandManager
.RegisterClassCommandBinding(ownerType,
115
CommandManager
.RegisterClassCommandBinding(ownerType,
117
CommandManager
.RegisterClassCommandBinding(ownerType,
Microsoft\Windows\Controls\Ribbon\RibbonGallery.cs (1)
78
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(FilterCommand, FilterExecuted, FilterCanExecute));
Microsoft\Windows\Controls\Ribbon\RibbonWindow.cs (5)
60
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(_minimizeWindowCommand, MinimizeWindowExecuted, MinimizeWindowCanExecute));
61
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(_maximizeWindowCommand, MaximizeWindowExecuted, MaximizeWindowCanExecute));
62
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(_restoreWindowCommand, RestoreWindowExecuted, RestoreWindowCanExecute));
63
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(_closeWindowCommand, CloseWindowExecuted, CloseWindowCanExecute));
64
CommandManager
.RegisterClassCommandBinding(ownerType, new CommandBinding(_showSystemMenuCommand, SystemMenuExecuted, SystemMenuCanExecute));