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