1 instantiation of CommandManager
PresentationCore (1)
System\Windows\Input\Command\CommandManager.cs (1)
251_commandManager = new CommandManager();
146 references to CommandManager
PresentationCore (38)
System\Windows\Generated\UIElement.cs (12)
781EventManager.RegisterClassHandler(type, CommandManager.PreviewExecutedEvent, new ExecutedRoutedEventHandler(UIElement.OnPreviewExecutedThunk), false); 782EventManager.RegisterClassHandler(type, CommandManager.ExecutedEvent, new ExecutedRoutedEventHandler(UIElement.OnExecutedThunk), false); 783EventManager.RegisterClassHandler(type, CommandManager.PreviewCanExecuteEvent, new CanExecuteRoutedEventHandler(UIElement.OnPreviewCanExecuteThunk), false); 784EventManager.RegisterClassHandler(type, CommandManager.CanExecuteEvent, new CanExecuteRoutedEventHandler(UIElement.OnCanExecuteThunk), false); 845CommandManager.TranslateInput((IInputElement)sender, e); 1212CommandManager.TranslateInput((IInputElement)sender, e); 1942CommandManager.TranslateInput((IInputElement)sender, e); 2173CommandManager.OnExecuted(sender, e); 2181CommandManager.OnExecuted(sender, e); 2189CommandManager.OnCanExecute(sender, e); 2197CommandManager.OnCanExecute(sender, e); 2205CommandManager.OnCommandDevice(sender, e);
System\Windows\Input\Command\CanExecuteChangedEventManager.cs (1)
454if (sender is CommandManager)
System\Windows\Input\Command\CommandBinding.cs (3)
123if (e.RoutedEvent == CommandManager.CanExecuteEvent) 157RoutedEvent = CommandManager.CanExecuteEvent, 177if (e.RoutedEvent == CommandManager.ExecutedEvent)
System\Windows\Input\Command\CommandDevice.cs (1)
113CommandManager.InvalidateRequerySuggested();
System\Windows\Input\Command\CommandManager.cs (15)
40typeof(CommandManager)); 75typeof(CommandManager)); 110typeof(CommandManager)); 145typeof(CommandManager)); 235CommandManager.Current.RaiseRequerySuggested(); 245private static CommandManager Current 511RoutedEvent = CommandManager.CanExecuteEvent, 520RoutedEvent = CommandManager.ExecutedEvent, 753private static CommandManager _commandManager; 839public static void AddHandler(CommandManager source, EventHandler handler) 850public static void RemoveHandler(CommandManager source, EventHandler handler) 879CommandManager typedSource = CommandManager.Current; 888CommandManager typedSource = CommandManager.Current;
System\Windows\Input\Command\RoutedCommand.cs (6)
105add { CommandManager.RequerySuggested += value; } 106remove { CommandManager.RequerySuggested -= value; } 324RoutedEvent = CommandManager.PreviewCanExecuteEvent 329args.RoutedEvent = CommandManager.CanExecuteEvent; 385RoutedEvent = CommandManager.PreviewExecutedEvent 411args.RoutedEvent = CommandManager.ExecutedEvent;
PresentationFramework (87)
MS\Internal\AppModel\JournalNavigationScope.cs (1)
473System.Windows.Input.CommandManager.InvalidateRequerySuggested();
MS\Internal\Commands\CommandHelpers.cs (2)
102CommandManager.RegisterClassCommandBinding(controlType, new CommandBinding(command, executedRoutedEventHandler, canExecuteRoutedEventHandler)); 107CommandManager.RegisterClassInputBinding(controlType, new InputBinding(command, inputGestures[i]));
System\Windows\Annotations\AnnotationService.cs (18)
46CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand)); 48CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand)); 50CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand)); 52CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand)); 54CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand)); 56CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand)); 58CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand)); 60CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand)); 62CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand)); 64CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand)); 66CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand)); 68CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand)); 70CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand)); 72CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand)); 74CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand)); 76CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand)); 78CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand)); 80CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand));
System\Windows\Controls\DataGrid.cs (22)
57CommandManager.RegisterClassInputBinding(ownerType, new InputBinding(BeginEditCommand, new KeyGesture(Key.F2))); 58CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(BeginEditCommand, new ExecutedRoutedEventHandler(OnExecutedBeginEdit), new CanExecuteRoutedEventHandler(OnCanExecuteBeginEdit))); 60CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(CommitEditCommand, new ExecutedRoutedEventHandler(OnExecutedCommitEdit), new CanExecuteRoutedEventHandler(OnCanExecuteCommitEdit))); 62CommandManager.RegisterClassInputBinding(ownerType, new InputBinding(CancelEditCommand, new KeyGesture(Key.Escape))); 63CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(CancelEditCommand, new ExecutedRoutedEventHandler(OnExecutedCancelEdit), new CanExecuteRoutedEventHandler(OnCanExecuteCancelEdit))); 65CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(SelectAllCommand, new ExecutedRoutedEventHandler(OnExecutedSelectAll), new CanExecuteRoutedEventHandler(OnCanExecuteSelectAll))); 67CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(DeleteCommand, new ExecutedRoutedEventHandler(OnExecutedDelete), new CanExecuteRoutedEventHandler(OnCanExecuteDelete))); 70CommandManager.RegisterClassCommandBinding(typeof(DataGrid), new CommandBinding(ApplicationCommands.Copy, new ExecutedRoutedEventHandler(OnExecutedCopy), new CanExecuteRoutedEventHandler(OnCanExecuteCopy))); 2281CommandManager.InvalidateRequerySuggested(); 2411CommandManager.InvalidateRequerySuggested(); 2576CommandManager.InvalidateRequerySuggested(); 2789CommandManager.InvalidateRequerySuggested(); 3046CommandManager.InvalidateRequerySuggested(); 3394CommandManager.InvalidateRequerySuggested(); 3413CommandManager.InvalidateRequerySuggested(); 3516CommandManager.InvalidateRequerySuggested(); 3596CommandManager.InvalidateRequerySuggested(); 3606CommandManager.InvalidateRequerySuggested(); 4290CommandManager.InvalidateRequerySuggested(); 4560CommandManager.InvalidateRequerySuggested(); 5416CommandManager.InvalidateRequerySuggested(); 8240CommandManager.InvalidateRequerySuggested();
System\Windows\Controls\DataGridCell.cs (1)
229CommandManager.InvalidateRequerySuggested();
System\Windows\Controls\DocumentViewer.cs (3)
1699CommandManager.RegisterClassInputBinding(typeof(DocumentViewer), 1711CommandManager.RegisterClassInputBinding(typeof(DocumentViewer), 1723CommandManager.RegisterClassInputBinding(typeof(DocumentViewer),
System\Windows\Controls\FlowDocumentReader.cs (8)
671CommandManager.InvalidateRequerySuggested(); 1168CommandManager.AddPreviewCanExecuteHandler(_pageViewer, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1178CommandManager.AddPreviewCanExecuteHandler(_twoPageViewer, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1188CommandManager.AddPreviewCanExecuteHandler(_scrollViewer, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1246CommandManager.InvalidateRequerySuggested(); 1714CommandManager.InvalidateRequerySuggested(); 1726CommandManager.InvalidateRequerySuggested(); 1739CommandManager.InvalidateRequerySuggested();
System\Windows\Controls\FlowDocumentScrollViewer.cs (5)
569CommandManager.InvalidateRequerySuggested(); 578CommandManager.AddPreviewCanExecuteHandler(_contentHost, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1072CommandManager.RemovePreviewCanExecuteHandler(_contentHost, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1086CommandManager.InvalidateRequerySuggested(); 1632CommandManager.InvalidateRequerySuggested();
System\Windows\Controls\MenuItem.cs (1)
607CommandManager.InvalidateRequerySuggested(); // Should post an idle queue item to update IsEnabled on commands
System\Windows\Controls\Primitives\DocumentViewerBase.cs (4)
578CommandManager.InvalidateRequerySuggested(); 1254CommandManager.InvalidateRequerySuggested(); 1428CommandManager.InvalidateRequerySuggested(); 1603CommandManager.InvalidateRequerySuggested();
System\Windows\Controls\Primitives\Track.cs (2)
176CommandManager.InvalidateRequerySuggested(); // Should post an idle queue item to update IsEnabled on button 217CommandManager.InvalidateRequerySuggested(); // Should post an idle queue item to update IsEnabled on button
System\Windows\Controls\SinglePageViewer.cs (14)
677CommandManager.InvalidateRequerySuggested(); 684CommandManager.AddPreviewCanExecuteHandler(this, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1105CommandManager.RemovePreviewCanExecuteHandler(this, new CanExecuteRoutedEventHandler(PreviewCanExecuteRoutedEventHandler)); 1117CommandManager.InvalidateRequerySuggested(); 1272CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.PreviousPage, new KeyGesture(Key.Left))); 1273CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.PreviousPage, new KeyGesture(Key.Up))); 1274CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.PreviousPage, new KeyGesture(Key.PageUp))); 1275CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.NextPage, new KeyGesture(Key.Right))); 1276CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.NextPage, new KeyGesture(Key.Down))); 1277CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.NextPage, new KeyGesture(Key.PageDown))); 1278CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.FirstPage, new KeyGesture(Key.Home))); 1279CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.FirstPage, new KeyGesture(Key.Home, ModifierKeys.Control))); 1280CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.LastPage, new KeyGesture(Key.End))); 1281CommandManager.RegisterClassInputBinding(typeof(FlowDocumentPageViewer), new InputBinding(NavigationCommands.LastPage, new KeyGesture(Key.End, ModifierKeys.Control)));
System\Windows\Navigation\NavigationWindow.cs (5)
158CommandManager.RegisterClassCommandBinding( 165CommandManager.RegisterClassCommandBinding( 172CommandManager.RegisterClassCommandBinding( 176CommandManager.RegisterClassCommandBinding( 183CommandManager.RegisterClassCommandBinding(
System\Windows\Window.cs (1)
3573CommandManager.RegisterClassCommandBinding(typeof(Window), binding);
PresentationUI (9)
InstallationError.xaml.cs (1)
20CommandManager.RegisterClassCommandBinding(typeof(InstallationErrorPage),
MS\Internal\Documents\DocumentApplicationDocumentViewer.cs (5)
324CommandManager.InvalidateRequerySuggested(); 343CommandManager.InvalidateRequerySuggested(); 381CommandManager.InvalidateRequerySuggested(); 2129CommandManager.RegisterClassCommandBinding(typeof(DocumentApplicationDocumentViewer), 2137CommandManager.RegisterClassInputBinding(typeof(DocumentApplicationDocumentViewer),
TenFeetInstallationError.xaml.cs (1)
27CommandManager.RegisterClassCommandBinding(typeof(TenFeetInstallationError),
TenFeetInstallationProgress.xaml.cs (2)
28CommandManager.RegisterClassCommandBinding(typeof(TenFeetInstallationProgress), 33CommandManager.RegisterClassCommandBinding(typeof(TenFeetInstallationProgress),
System.Windows.Controls.Ribbon (12)
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (6)
104CommandManager.RegisterClassCommandBinding(ownerType, 106CommandManager.RegisterClassCommandBinding(ownerType, 108CommandManager.RegisterClassCommandBinding(ownerType, 110CommandManager.RegisterClassCommandBinding(ownerType, 112CommandManager.RegisterClassCommandBinding(ownerType, 114CommandManager.RegisterClassCommandBinding(ownerType,
Microsoft\Windows\Controls\Ribbon\RibbonGallery.cs (1)
76CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(FilterCommand, FilterExecuted, FilterCanExecute));
Microsoft\Windows\Controls\Ribbon\RibbonWindow.cs (5)
55CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(_minimizeWindowCommand, MinimizeWindowExecuted, MinimizeWindowCanExecute)); 56CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(_maximizeWindowCommand, MaximizeWindowExecuted, MaximizeWindowCanExecute)); 57CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(_restoreWindowCommand, RestoreWindowExecuted, RestoreWindowCanExecute)); 58CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(_closeWindowCommand, CloseWindowExecuted, CloseWindowCanExecute)); 59CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(_showSystemMenuCommand, SystemMenuExecuted, SystemMenuCanExecute));