63 instantiations of CommandBinding
Microsoft.VisualStudio.LanguageServices (8)
GenerateType\GenerateTypeDialog.xaml.cs (5)
49CommandBindings.Add(new CommandBinding( 56CommandBindings.Add(new CommandBinding( 63CommandBindings.Add(new CommandBinding( 70CommandBindings.Add(new CommandBinding( 77CommandBindings.Add(new CommandBinding(
PickMembers\PickMembersDialog.xaml.cs (2)
48CommandBindings.Add(new CommandBinding( 55CommandBindings.Add(new CommandBinding(
StackTraceExplorer\StackTraceExplorerToolWindow.cs (1)
47dockPanel.CommandBindings.Add(new CommandBinding(ApplicationCommands.Paste, (s, e) =>
PresentationFramework (38)
MS\Internal\Commands\CommandHelpers.cs (1)
102CommandManager.RegisterClassCommandBinding(controlType, new CommandBinding(command, executedRoutedEventHandler, canExecuteRoutedEventHandler));
System\Windows\Annotations\AnnotationService.cs (18)
47CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand)); 49CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand)); 51CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand)); 53CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand)); 55CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand)); 57CommandManager.RegisterClassCommandBinding(typeof(DocumentViewerBase), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand)); 59CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand)); 61CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand)); 63CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand)); 65CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand)); 67CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand)); 69CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentScrollViewer), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand)); 71CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateHighlightCommand, AnnotationHelper.OnCreateHighlightCommand, AnnotationHelper.OnQueryCreateHighlightCommand)); 73CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateTextStickyNoteCommand, AnnotationHelper.OnCreateTextStickyNoteCommand, AnnotationHelper.OnQueryCreateTextStickyNoteCommand)); 75CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(CreateInkStickyNoteCommand, AnnotationHelper.OnCreateInkStickyNoteCommand, AnnotationHelper.OnQueryCreateInkStickyNoteCommand)); 77CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(ClearHighlightsCommand, AnnotationHelper.OnClearHighlightsCommand, AnnotationHelper.OnQueryClearHighlightsCommand)); 79CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(DeleteStickyNotesCommand, AnnotationHelper.OnDeleteStickyNotesCommand, AnnotationHelper.OnQueryDeleteStickyNotesCommand)); 81CommandManager.RegisterClassCommandBinding(typeof(FlowDocumentReader), new CommandBinding(DeleteAnnotationsCommand, AnnotationHelper.OnDeleteAnnotationsCommand, AnnotationHelper.OnQueryDeleteAnnotationsCommand));
System\Windows\Controls\DataGrid.cs (6)
58CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(BeginEditCommand, new ExecutedRoutedEventHandler(OnExecutedBeginEdit), new CanExecuteRoutedEventHandler(OnCanExecuteBeginEdit))); 60CommandManager.RegisterClassCommandBinding(ownerType, new CommandBinding(CommitEditCommand, new ExecutedRoutedEventHandler(OnExecutedCommitEdit), new CanExecuteRoutedEventHandler(OnCanExecuteCommitEdit))); 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)));
System\Windows\Controls\Frame.cs (5)
1350AddCommandBinding(new CommandBinding(NavigationCommands.BrowseBack, OnGoBack, OnQueryGoBack)); 1351AddCommandBinding(new CommandBinding(NavigationCommands.BrowseForward, OnGoForward, OnQueryGoForward)); 1352AddCommandBinding(new CommandBinding(NavigationCommands.NavigateJournal, OnNavigateJournal)); 1353AddCommandBinding(new CommandBinding(NavigationCommands.Refresh, OnRefresh, OnQueryRefresh)); 1354AddCommandBinding(new CommandBinding(NavigationCommands.BrowseStop, OnBrowseStop));
System\Windows\Documents\RubberbandSelector.cs (1)
69CommandBinding binding = new CommandBinding(ApplicationCommands.Copy);
System\Windows\Markup\Baml2006\WpfGeneratedKnownTypes.cs (1)
11538bamlType.DefaultConstructor = delegate() { return new System.Windows.Input.CommandBinding(); };
System\Windows\Navigation\NavigationWindow.cs (5)
160new CommandBinding( 167new CommandBinding( 174new CommandBinding(NavigationCommands.NavigateJournal, new ExecutedRoutedEventHandler(OnNavigateJournal))); 178new CommandBinding( 185new CommandBinding(
System\Windows\Window.cs (1)
3576CommandBinding binding = new CommandBinding(DialogCancelCommand);
PresentationUI (5)
InstallationError.xaml.cs (1)
21new CommandBinding(NavigationCommands.Refresh,
MS\Internal\Documents\DocumentApplicationDocumentViewer.cs (1)
2127new CommandBinding(command, executeHandler, queryEnabledHandler));
TenFeetInstallationError.xaml.cs (1)
28new CommandBinding(NavigationCommands.Refresh,
TenFeetInstallationProgress.xaml.cs (2)
29new CommandBinding(NavigationCommands.Refresh, 34new CommandBinding(NavigationCommands.BrowseStop,
System.Windows.Controls.Ribbon (12)
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (6)
105new CommandBinding(RibbonCommands.AddToQuickAccessToolBarCommand, AddToQATExecuted, AddToQATCanExecute)); 107new CommandBinding(RibbonCommands.MaximizeRibbonCommand, MaximizeRibbonExecuted, MaximizeRibbonCanExecute)); 109new CommandBinding(RibbonCommands.MinimizeRibbonCommand, MinimizeRibbonExecuted, MinimizeRibbonCanExecute)); 111new CommandBinding(RibbonCommands.RemoveFromQuickAccessToolBarCommand, RemoveFromQATExecuted, RemoveFromQATCanExecute)); 113new CommandBinding(RibbonCommands.ShowQuickAccessToolBarAboveRibbonCommand, ShowQATAboveExecuted, ShowQATAboveCanExecute)); 115new CommandBinding(RibbonCommands.ShowQuickAccessToolBarBelowRibbonCommand, ShowQATBelowExecuted, ShowQATBelowCanExecute));
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));
58 references to CommandBinding
Microsoft.VisualStudio.LanguageServices (13)
artifacts\obj\Microsoft.VisualStudio.LanguageServices\Release\net472\ChangeSignature\ChangeSignatureDialog.g.cs (8)
263((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveUp_Click_FocusRow); 271((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveUp_Click); 279((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveDown_Click_FocusRow); 287((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveDown_Click); 295((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.ToggleRemovedState); 318((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveSelectionUp_Click); 326((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveSelectionDown_Click); 334((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.OK_Click);
artifacts\obj\Microsoft.VisualStudio.LanguageServices\Release\net472\PickMembers\PickMembersDialog.g.cs (2)
160((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveUp_Click); 168((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.MoveDown_Click);
artifacts\obj\Microsoft.VisualStudio.LanguageServices\Release\net472\StackTraceExplorer\StackTraceExplorer.g.cs (3)
77((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed); 85((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed); 109((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed);
PresentationCore (32)
System\Windows\Input\Command\CommandBindingCollection.cs (22)
78return Contains(key as CommandBinding) ; 88return ((value is CommandBinding commandBinding) ? IndexOf(commandBinding) : -1); 98Insert(index, value as CommandBinding); 107return Add(commandBinding as CommandBinding); 116Remove(commandBinding as CommandBinding); 130if (value is not CommandBinding commandBinding) 140public CommandBinding this[int index] 159public int Add(CommandBinding commandBinding) 163_innerCBList ??= new Collections.Generic.List<CommandBinding>(1); 185_innerCBList ??= new System.Collections.Generic.List<CommandBinding>(collection.Count); 190if (collectionEnum.Current is CommandBinding cmdBinding) 206public void Insert(int index, CommandBinding commandBinding) 222public void Remove(CommandBinding commandBinding) 301public int IndexOf(CommandBinding value) 311public bool Contains(CommandBinding commandBinding) 325public void CopyTo(CommandBinding[] commandBindings, int index) 340System.Collections.Generic.List<CommandBinding> list = new System.Collections.Generic.List<CommandBinding>(0); 353CommandBinding commandBinding = this[i]; 365internal CommandBinding FindMatch(ICommand command, ref int index) 369CommandBinding commandBinding = this[index++]; 386private Collections.Generic.List<CommandBinding> _innerCBList;
System\Windows\Input\Command\CommandManager.cs (10)
211public static void RegisterClassCommandBinding(Type type, CommandBinding commandBinding) 464private static bool CanExecuteCommandBinding(object sender, CanExecuteRoutedEventArgs e, CommandBinding commandBinding) 499private static bool ExecuteCommandBinding(object sender, ExecutedRoutedEventArgs e, CommandBinding commandBinding) 550ValueTuple<Type, CommandBinding>? tuple = default; // zero or one binding 551List<ValueTuple<Type, CommandBinding>> list = default; // more than one 564CommandBinding commandBinding = classCommandBindings.FindMatch(command, ref index); 576list ??= new List<ValueTuple<Type, CommandBinding>>(8) 581list.Add(new ValueTuple<Type, CommandBinding>(classType, commandBinding)); 629CommandBinding commandBinding = commandBindings.FindMatch(command, ref index); 637private static bool HandleCommandBinding(object sender, RoutedEventArgs e, CommandBinding commandBinding, bool execute)
PresentationFramework (13)
System\Windows\Controls\Frame.cs (4)
1370foreach (CommandBinding cb in _commandBindings) 1379private void AddCommandBinding(CommandBinding b) 1387_commandBindings = new List<CommandBinding>(6); 1409private List<CommandBinding> _commandBindings;
System\Windows\Documents\RubberbandSelector.cs (2)
69CommandBinding binding = new CommandBinding(ApplicationCommands.Copy); 96foreach (CommandBinding binding in commandBindings)
System\Windows\FrameworkCompatibilityPreferences.cs (1)
361/// <see cref="System.Windows.Input.CommandBinding"/>, and apply that binding to all TextBoxBase
System\Windows\Markup\Baml2006\WpfGeneratedKnownProperties.cs (4)
6984Type type = typeof(System.Windows.Input.CommandBinding); 6986this.GetXamlType(typeof(System.Windows.Input.CommandBinding)), // DeclaringType 6993bamlMember.SetDelegate = delegate(object target, object value) { ((System.Windows.Input.CommandBinding)target).Command = (System.Windows.Input.ICommand)value; }; 6994bamlMember.GetDelegate = delegate(object target) { return ((System.Windows.Input.CommandBinding)target).Command; };
System\Windows\Markup\Baml2006\WpfGeneratedKnownTypes.cs (1)
11536typeof(System.Windows.Input.CommandBinding),
System\Windows\Window.cs (1)
3576CommandBinding binding = new CommandBinding(DialogCancelCommand);