471 references to Keyboard
PresentationCore (198)
Core\CSharp\MS\Internal\Automation\ElementProxy.cs (1)
367AutomationPeer focusedPeer = AutomationPeer.AutomationPeerFromInputElement(Keyboard.FocusedElement);
Core\CSharp\MS\Internal\SynchronizedInputHelper.cs (5)
46return (re == Keyboard.KeyUpEvent || 47re == Keyboard.KeyDownEvent || 116return args.RoutedEvent == Keyboard.KeyDownEvent; 273e = new RoutedEvent[] {Keyboard.KeyUpEvent}; 276e = new RoutedEvent[] {Keyboard.KeyDownEvent, TextCompositionManager.TextInputEvent};
Core\CSharp\System\Windows\Automation\Peers\ContentElementAutomationPeer.cs (1)
196return Keyboard.IsFocusable(_owner);
Core\CSharp\System\Windows\Automation\Peers\UIElement3DAutomationPeer.cs (1)
307return Keyboard.IsFocusable(_owner);
Core\CSharp\System\Windows\Automation\Peers\UIElementAutomationPeer.cs (1)
366return Keyboard.IsFocusable(_owner);
Core\CSharp\System\Windows\ContentElement.cs (3)
283Keyboard.PrimaryDevice.ReevaluateFocusAsync(this, oldParent, isCoreParent); 486return (Keyboard.FocusedElement == this); 494if (Keyboard.Focus(this) == this)
Core\CSharp\System\Windows\Generated\ContentElement.cs (24)
1697public static readonly RoutedEvent PreviewKeyDownEvent = Keyboard.PreviewKeyDownEvent.AddOwner(_typeofThis); 1704add { AddHandler(Keyboard.PreviewKeyDownEvent, value, false); } 1705remove { RemoveHandler(Keyboard.PreviewKeyDownEvent, value); } 1716public static readonly RoutedEvent KeyDownEvent = Keyboard.KeyDownEvent.AddOwner(_typeofThis); 1723add { AddHandler(Keyboard.KeyDownEvent, value, false); } 1724remove { RemoveHandler(Keyboard.KeyDownEvent, value); } 1735public static readonly RoutedEvent PreviewKeyUpEvent = Keyboard.PreviewKeyUpEvent.AddOwner(_typeofThis); 1742add { AddHandler(Keyboard.PreviewKeyUpEvent, value, false); } 1743remove { RemoveHandler(Keyboard.PreviewKeyUpEvent, value); } 1754public static readonly RoutedEvent KeyUpEvent = Keyboard.KeyUpEvent.AddOwner(_typeofThis); 1761add { AddHandler(Keyboard.KeyUpEvent, value, false); } 1762remove { RemoveHandler(Keyboard.KeyUpEvent, value); } 1773public static readonly RoutedEvent PreviewGotKeyboardFocusEvent = Keyboard.PreviewGotKeyboardFocusEvent.AddOwner(_typeofThis); 1780add { AddHandler(Keyboard.PreviewGotKeyboardFocusEvent, value, false); } 1781remove { RemoveHandler(Keyboard.PreviewGotKeyboardFocusEvent, value); } 1792public static readonly RoutedEvent GotKeyboardFocusEvent = Keyboard.GotKeyboardFocusEvent.AddOwner(_typeofThis); 1799add { AddHandler(Keyboard.GotKeyboardFocusEvent, value, false); } 1800remove { RemoveHandler(Keyboard.GotKeyboardFocusEvent, value); } 1811public static readonly RoutedEvent PreviewLostKeyboardFocusEvent = Keyboard.PreviewLostKeyboardFocusEvent.AddOwner(_typeofThis); 1818add { AddHandler(Keyboard.PreviewLostKeyboardFocusEvent, value, false); } 1819remove { RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, value); } 1830public static readonly RoutedEvent LostKeyboardFocusEvent = Keyboard.LostKeyboardFocusEvent.AddOwner(_typeofThis); 1837add { AddHandler(Keyboard.LostKeyboardFocusEvent, value, false); } 1838remove { RemoveHandler(Keyboard.LostKeyboardFocusEvent, value); }
Core\CSharp\System\Windows\Generated\UIElement.cs (32)
848EventManager.RegisterClassHandler(type, Keyboard.PreviewKeyDownEvent, new KeyEventHandler(UIElement.OnPreviewKeyDownThunk), false); 849EventManager.RegisterClassHandler(type, Keyboard.KeyDownEvent, new KeyEventHandler(UIElement.OnKeyDownThunk), false); 850EventManager.RegisterClassHandler(type, Keyboard.PreviewKeyUpEvent, new KeyEventHandler(UIElement.OnPreviewKeyUpThunk), false); 851EventManager.RegisterClassHandler(type, Keyboard.KeyUpEvent, new KeyEventHandler(UIElement.OnKeyUpThunk), false); 852EventManager.RegisterClassHandler(type, Keyboard.PreviewGotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(UIElement.OnPreviewGotKeyboardFocusThunk), false); 853EventManager.RegisterClassHandler(type, Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(UIElement.OnGotKeyboardFocusThunk), false); 854EventManager.RegisterClassHandler(type, Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(UIElement.OnPreviewLostKeyboardFocusThunk), false); 855EventManager.RegisterClassHandler(type, Keyboard.LostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(UIElement.OnLostKeyboardFocusThunk), false); 3975public static readonly RoutedEvent PreviewKeyDownEvent = Keyboard.PreviewKeyDownEvent.AddOwner(_typeofThis); 3982add { AddHandler(Keyboard.PreviewKeyDownEvent, value, false); } 3983remove { RemoveHandler(Keyboard.PreviewKeyDownEvent, value); } 3994public static readonly RoutedEvent KeyDownEvent = Keyboard.KeyDownEvent.AddOwner(_typeofThis); 4001add { AddHandler(Keyboard.KeyDownEvent, value, false); } 4002remove { RemoveHandler(Keyboard.KeyDownEvent, value); } 4013public static readonly RoutedEvent PreviewKeyUpEvent = Keyboard.PreviewKeyUpEvent.AddOwner(_typeofThis); 4020add { AddHandler(Keyboard.PreviewKeyUpEvent, value, false); } 4021remove { RemoveHandler(Keyboard.PreviewKeyUpEvent, value); } 4032public static readonly RoutedEvent KeyUpEvent = Keyboard.KeyUpEvent.AddOwner(_typeofThis); 4039add { AddHandler(Keyboard.KeyUpEvent, value, false); } 4040remove { RemoveHandler(Keyboard.KeyUpEvent, value); } 4051public static readonly RoutedEvent PreviewGotKeyboardFocusEvent = Keyboard.PreviewGotKeyboardFocusEvent.AddOwner(_typeofThis); 4058add { AddHandler(Keyboard.PreviewGotKeyboardFocusEvent, value, false); } 4059remove { RemoveHandler(Keyboard.PreviewGotKeyboardFocusEvent, value); } 4070public static readonly RoutedEvent GotKeyboardFocusEvent = Keyboard.GotKeyboardFocusEvent.AddOwner(_typeofThis); 4077add { AddHandler(Keyboard.GotKeyboardFocusEvent, value, false); } 4078remove { RemoveHandler(Keyboard.GotKeyboardFocusEvent, value); } 4089public static readonly RoutedEvent PreviewLostKeyboardFocusEvent = Keyboard.PreviewLostKeyboardFocusEvent.AddOwner(_typeofThis); 4096add { AddHandler(Keyboard.PreviewLostKeyboardFocusEvent, value, false); } 4097remove { RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, value); } 4108public static readonly RoutedEvent LostKeyboardFocusEvent = Keyboard.LostKeyboardFocusEvent.AddOwner(_typeofThis); 4115add { AddHandler(Keyboard.LostKeyboardFocusEvent, value, false); } 4116remove { RemoveHandler(Keyboard.LostKeyboardFocusEvent, value); }
Core\CSharp\System\Windows\Generated\UIElement3D.cs (24)
1403public static readonly RoutedEvent PreviewKeyDownEvent = Keyboard.PreviewKeyDownEvent.AddOwner(_typeofThis); 1410add { AddHandler(Keyboard.PreviewKeyDownEvent, value, false); } 1411remove { RemoveHandler(Keyboard.PreviewKeyDownEvent, value); } 1422public static readonly RoutedEvent KeyDownEvent = Keyboard.KeyDownEvent.AddOwner(_typeofThis); 1429add { AddHandler(Keyboard.KeyDownEvent, value, false); } 1430remove { RemoveHandler(Keyboard.KeyDownEvent, value); } 1441public static readonly RoutedEvent PreviewKeyUpEvent = Keyboard.PreviewKeyUpEvent.AddOwner(_typeofThis); 1448add { AddHandler(Keyboard.PreviewKeyUpEvent, value, false); } 1449remove { RemoveHandler(Keyboard.PreviewKeyUpEvent, value); } 1460public static readonly RoutedEvent KeyUpEvent = Keyboard.KeyUpEvent.AddOwner(_typeofThis); 1467add { AddHandler(Keyboard.KeyUpEvent, value, false); } 1468remove { RemoveHandler(Keyboard.KeyUpEvent, value); } 1479public static readonly RoutedEvent PreviewGotKeyboardFocusEvent = Keyboard.PreviewGotKeyboardFocusEvent.AddOwner(_typeofThis); 1486add { AddHandler(Keyboard.PreviewGotKeyboardFocusEvent, value, false); } 1487remove { RemoveHandler(Keyboard.PreviewGotKeyboardFocusEvent, value); } 1498public static readonly RoutedEvent GotKeyboardFocusEvent = Keyboard.GotKeyboardFocusEvent.AddOwner(_typeofThis); 1505add { AddHandler(Keyboard.GotKeyboardFocusEvent, value, false); } 1506remove { RemoveHandler(Keyboard.GotKeyboardFocusEvent, value); } 1517public static readonly RoutedEvent PreviewLostKeyboardFocusEvent = Keyboard.PreviewLostKeyboardFocusEvent.AddOwner(_typeofThis); 1524add { AddHandler(Keyboard.PreviewLostKeyboardFocusEvent, value, false); } 1525remove { RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, value); } 1536public static readonly RoutedEvent LostKeyboardFocusEvent = Keyboard.LostKeyboardFocusEvent.AddOwner(_typeofThis); 1543add { AddHandler(Keyboard.LostKeyboardFocusEvent, value, false); } 1544remove { RemoveHandler(Keyboard.LostKeyboardFocusEvent, value); }
Core\CSharp\System\Windows\Input\AccessKeyManager.cs (2)
235if (e.StagingItem.Input.RoutedEvent == Keyboard.KeyDownEvent) 430(scope is PresentationSource) && (Keyboard.Modifiers & ModifierKeys.Alt) != ModifierKeys.Alt)
Core\CSharp\System\Windows\Input\Command\CommandDevice.cs (5)
46return Keyboard.FocusedElement; 135else if (e.StagingItem.Input.RoutedEvent == Keyboard.KeyUpEvent || 137e.StagingItem.Input.RoutedEvent == Keyboard.GotKeyboardFocusEvent || 138e.StagingItem.Input.RoutedEvent == Keyboard.LostKeyboardFocusEvent) 311return Keyboard.FocusedElement;
Core\CSharp\System\Windows\Input\Command\KeyGesture.cs (1)
186return ( ( (int)Key == (int)keyEventArgs.RealKey ) && ( this.Modifiers == Keyboard.Modifiers ) );
Core\CSharp\System\Windows\Input\Command\MouseGesture.cs (1)
139return ( ( (int)this.MouseAction == (int)mouseAction ) && ( this.Modifiers == Keyboard.Modifiers ) );
Core\CSharp\System\Windows\Input\Command\RoutedCommand.cs (5)
100Execute(parameter, FilterInputElement(Keyboard.FocusedElement)); 116return CanExecuteImpl(parameter, FilterInputElement(Keyboard.FocusedElement), false, out unused); 156target = FilterInputElement(Keyboard.FocusedElement); 201target = FilterInputElement(Keyboard.FocusedElement); 432target = FilterInputElement(Keyboard.FocusedElement);
Core\CSharp\System\Windows\Input\DefaultTextStore.cs (2)
176_composition = new DefaultTextStoreTextComposition(InputManager.Current, Keyboard.FocusedElement, result, TextCompositionAutoComplete.On); 207_composition = new DefaultTextStoreTextComposition(InputManager.Current, Keyboard.FocusedElement, "", TextCompositionAutoComplete.Off);
Core\CSharp\System\Windows\Input\FocusManager.cs (3)
251DependencyObject oldFocus = Keyboard.FocusedElement as DependencyObject; 253DependencyObject newFocus = Keyboard.FocusedElement as DependencyObject; 263Keyboard.Focus(newFocusedElement);
Core\CSharp\System\Windows\Input\InputMethod.cs (8)
598IntPtr hwnd = HwndFromInputElement(Keyboard.FocusedElement); 636hwnd = HwndFromInputElement(Keyboard.FocusedElement); 867IntPtr hwnd = HwndFromInputElement(Keyboard.FocusedElement); 919hwnd = HwndFromInputElement(Keyboard.FocusedElement); 1131IntPtr hwnd = HwndFromInputElement(Keyboard.FocusedElement); 1206IntPtr hwnd = HwndFromInputElement(Keyboard.FocusedElement); 1405if (inputElement == Keyboard.FocusedElement) 1445hwnd = HwndFromInputElement(Keyboard.FocusedElement);
Core\CSharp\System\Windows\Input\Keyboard.cs (20)
24public static readonly RoutedEvent PreviewKeyDownEvent = EventManager.RegisterRoutedEvent("PreviewKeyDown", RoutingStrategy.Tunnel, typeof(KeyEventHandler), typeof(Keyboard)); 49public static readonly RoutedEvent KeyDownEvent = EventManager.RegisterRoutedEvent("KeyDown", RoutingStrategy.Bubble, typeof(KeyEventHandler), typeof(Keyboard)); 74public static readonly RoutedEvent PreviewKeyUpEvent = EventManager.RegisterRoutedEvent("PreviewKeyUp", RoutingStrategy.Tunnel, typeof(KeyEventHandler), typeof(Keyboard)); 99public static readonly RoutedEvent KeyUpEvent = EventManager.RegisterRoutedEvent("KeyUp", RoutingStrategy.Bubble, typeof(KeyEventHandler), typeof(Keyboard)); 124public static readonly RoutedEvent PreviewGotKeyboardFocusEvent = EventManager.RegisterRoutedEvent("PreviewGotKeyboardFocus", RoutingStrategy.Tunnel, typeof(KeyboardFocusChangedEventHandler), typeof(Keyboard)); 149public static readonly RoutedEvent PreviewKeyboardInputProviderAcquireFocusEvent = EventManager.RegisterRoutedEvent("PreviewKeyboardInputProviderAcquireFocus", RoutingStrategy.Tunnel, typeof(KeyboardInputProviderAcquireFocusEventHandler), typeof(Keyboard)); 174public static readonly RoutedEvent KeyboardInputProviderAcquireFocusEvent = EventManager.RegisterRoutedEvent("KeyboardInputProviderAcquireFocus", RoutingStrategy.Bubble, typeof(KeyboardInputProviderAcquireFocusEventHandler), typeof(Keyboard)); 199public static readonly RoutedEvent GotKeyboardFocusEvent = EventManager.RegisterRoutedEvent("GotKeyboardFocus", RoutingStrategy.Bubble, typeof(KeyboardFocusChangedEventHandler), typeof(Keyboard)); 224public static readonly RoutedEvent PreviewLostKeyboardFocusEvent = EventManager.RegisterRoutedEvent("PreviewLostKeyboardFocus", RoutingStrategy.Tunnel, typeof(KeyboardFocusChangedEventHandler), typeof(Keyboard)); 249public static readonly RoutedEvent LostKeyboardFocusEvent = EventManager.RegisterRoutedEvent("LostKeyboardFocus", RoutingStrategy.Bubble, typeof(KeyboardFocusChangedEventHandler), typeof(Keyboard)); 278return Keyboard.PrimaryDevice.FocusedElement; 288Keyboard.PrimaryDevice.ClearFocus(); 299return Keyboard.PrimaryDevice.Focus(element); 309return Keyboard.PrimaryDevice.DefaultRestoreFocusMode; 314Keyboard.PrimaryDevice.DefaultRestoreFocusMode = value; 325return Keyboard.PrimaryDevice.Modifiers; 334return Keyboard.PrimaryDevice.IsKeyDown(key); 342return Keyboard.PrimaryDevice.IsKeyUp(key); 350return Keyboard.PrimaryDevice.IsKeyToggled(key); 358return Keyboard.PrimaryDevice.GetKeyStates(key);
Core\CSharp\System\Windows\Input\KeyboardDevice.cs (17)
196isValid = Keyboard.IsFocusable(focus); 357previewLostFocus.RoutedEvent=Keyboard.PreviewLostKeyboardFocusEvent; 375previewGotFocus.RoutedEvent=Keyboard.PreviewGotKeyboardFocusEvent; 391if (keyboardInputProvider != null && Keyboard.IsFocusable(newFocus)) 399acquireFocus.RoutedEvent = Keyboard.PreviewKeyboardInputProviderAcquireFocusEvent; 410acquireFocus.RoutedEvent = Keyboard.KeyboardInputProviderAcquireFocusEvent; 545lostFocus.RoutedEvent=Keyboard.LostKeyboardFocusEvent; 553gotFocus.RoutedEvent=Keyboard.GotKeyboardFocusEvent; 669if(Keyboard.IsFocusable(element)) 848if(e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyDownEvent) 872else if(e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyUpEvent) 893if(e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyDownEvent) 940keyDown.RoutedEvent=Keyboard.KeyDownEvent; 948if(e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyUpEvent) 994keyUp.RoutedEvent=Keyboard.KeyUpEvent; 1026previewKeyDown.RoutedEvent=Keyboard.PreviewKeyDownEvent; 1045previewKeyUp.RoutedEvent=Keyboard.PreviewKeyUpEvent;
Core\CSharp\System\Windows\Input\KeyEventArgs.cs (1)
39if (!Keyboard.IsValidKey(key))
Core\CSharp\System\Windows\Input\TextCompositionManager.cs (5)
549if (e.StagingItem.Input.RoutedEvent == Keyboard.KeyDownEvent) 594if (e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyDownEvent) 618if(e.StagingItem.Input.RoutedEvent == Keyboard.KeyUpEvent) 884if (!Keyboard.IsKeyDown(Key.LeftAlt) && !Keyboard.IsKeyDown(Key.RightAlt))
Core\CSharp\System\Windows\Input\TextServicesManager.cs (12)
138if(e.StagingItem.Input.RoutedEvent != Keyboard.PreviewKeyDownEvent && 139e.StagingItem.Input.RoutedEvent != Keyboard.PreviewKeyUpEvent) 152DependencyObject element = Keyboard.FocusedElement as DependencyObject; 192DependencyObject element = Keyboard.FocusedElement as DependencyObject; 200if(e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyDownEvent || 201e.StagingItem.Input.RoutedEvent == Keyboard.PreviewKeyUpEvent) 222else if(e.StagingItem.Input.RoutedEvent == Keyboard.KeyDownEvent || 223e.StagingItem.Input.RoutedEvent == Keyboard.KeyUpEvent) 265if (keyArgs.RoutedEvent == Keyboard.PreviewKeyDownEvent/*keyArgs.IsDown*/) 282if (Keyboard.IsKeyDown(Key.LeftAlt) || 283Keyboard.IsKeyDown(Key.RightAlt) || 284Keyboard.IsKeyDown(Key.F10))
Core\CSharp\System\Windows\Interop\HwndKeyboardInputProvider.cs (5)
61Keyboard.Focus(null); // internally we will set the focus to the root. 406DependencyObject focusedDO = Keyboard.FocusedElement as DependencyObject; 551Keyboard.Focus(restoreFocusDO as IInputElement); 561restoreFocusDO = (DependencyObject)Keyboard.FocusedElement; 567Keyboard.ClearFocus();
Core\CSharp\System\Windows\Interop\HwndSource.cs (12)
2397DependencyObject focusObject = Keyboard.FocusedElement as DependencyObject; 2681Keyboard.PrimaryDevice.ForceTarget = focusElement; 2686Keyboard.PrimaryDevice.ForceTarget = null; 2709keyPreviewEvent = Keyboard.PreviewKeyUpEvent; 2710keyEvent = Keyboard.KeyUpEvent; 2714keyPreviewEvent = Keyboard.PreviewKeyDownEvent; 2715keyEvent = Keyboard.KeyDownEvent; 2731focusElement = Keyboard.PrimaryDevice.FocusedElement; 2740Keyboard.PrimaryDevice.ForceTarget = focusSink as IInputElement; 2744KeyEventArgs tunnelArgs = new KeyEventArgs(Keyboard.PrimaryDevice, this, msg.time, key); 2754KeyEventArgs bubbleArgs = new KeyEventArgs(Keyboard.PrimaryDevice, this, msg.time, key); 2776Keyboard.PrimaryDevice.ForceTarget = null;
Core\CSharp\System\Windows\Interop\HwndSourceParameters.cs (1)
265get { return _restoreFocusMode ?? Keyboard.DefaultRestoreFocusMode; }
Core\CSharp\System\Windows\UIElement.cs (3)
2413Keyboard.PrimaryDevice.ReevaluateFocusAsync(this, oldParent, isCoreParent); 2622return (Keyboard.FocusedElement == this); 2630if (Keyboard.Focus(this) == this)
Core\CSharp\System\Windows\UIElement3D.cs (3)
373Keyboard.PrimaryDevice.ReevaluateFocusAsync(this, oldParent, isCoreParent); 582return (Keyboard.FocusedElement == this); 590if (Keyboard.Focus(this) == this)
PresentationFramework (185)
src\Framework\MS\Internal\AppModel\ApplicationProxyInternal.cs (2)
167TextBoxBase textBoxBase = Keyboard.FocusedElement as TextBoxBase; 173PasswordBox passwordBox = Keyboard.FocusedElement as PasswordBox;
src\Framework\MS\Internal\Documents\DocumentGrid.cs (2)
1290bool altKeyDown = Keyboard.IsKeyDown(Key.LeftAlt) || Keyboard.IsKeyDown(Key.RightAlt);
src\Framework\MS\Internal\Documents\DocumentViewerHelper.cs (1)
362DependencyObject focusedElement = Keyboard.FocusedElement as DependencyObject;
src\Framework\System\Windows\Controls\Button.cs (3)
93b.UpdateIsDefaulted(Keyboard.FocusedElement); 111b.UpdateIsDefaulted(Keyboard.FocusedElement); 195UpdateIsDefaulted(Keyboard.FocusedElement);
src\Framework\System\Windows\Controls\CalendarKeyboardHelper.cs (2)
9ctrl = (Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control; 10shift = (Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift;
src\Framework\System\Windows\Controls\ComboBox.cs (10)
1143DependencyObject currentFocus = Keyboard.FocusedElement as DependencyObject; 1361NavigateByLine(HighlightedInfo, FocusNavigationDirection.Up, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1381NavigateByLine(HighlightedInfo, FocusNavigationDirection.Down, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1420NavigateToStart(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1435NavigateToEnd(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1450NavigateByLine(HighlightedInfo, FocusNavigationDirection.Right, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1473NavigateByLine(HighlightedInfo, FocusNavigationDirection.Left, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1494NavigateByPage(HighlightedInfo, FocusNavigationDirection.Up, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1502NavigateByPage(HighlightedInfo, FocusNavigationDirection.Down, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1508if (Keyboard.Modifiers == ModifierKeys.Control)
src\Framework\System\Windows\Controls\ContextMenu.cs (4)
437NavigateToStart(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 446NavigateToEnd(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 610if (Keyboard.FocusedElement != null) 612_weakRefToPreviousFocus = new WeakReference<IInputElement>(Keyboard.FocusedElement);
src\Framework\System\Windows\Controls\DataGrid.cs (21)
1374(Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift; 5345(_isDraggingSelection || ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift)); 5357return (Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control; 5593UIElement startElement = Keyboard.FocusedElement as UIElement; 5594ContentElement startContentElement = (startElement == null) ? Keyboard.FocusedElement as ContentElement : null; 5607Keyboard.Focus(nextFocusTarget as IInputElement); 5721Keyboard.Focus(nextFocusTarget as IInputElement); 5767Keyboard.Focus(nextFocusTarget as IInputElement); 5801Keyboard.Focus(nextFocusTarget as IInputElement); 5836Keyboard.Focus(nextFocusTarget as IInputElement); 5883FrameworkElement startingElement = Keyboard.FocusedElement as FrameworkElement; 5890new ItemNavigateArgs(e.KeyboardDevice, Keyboard.Modifiers), 5927UIElement startElement = Keyboard.FocusedElement as UIElement; 5928ContentElement startContentElement = (startElement == null) ? Keyboard.FocusedElement as ContentElement : null; 5941if (wasEditing && previous && Keyboard.FocusedElement == currentCellContainer) 6036DataGridCell newCell = Keyboard.FocusedElement as DataGridCell; 6187startingElement = Keyboard.FocusedElement as FrameworkElement; 6207PrepareToNavigateByPage(startingInfo, startingElement, direction, new ItemNavigateArgs(Keyboard.PrimaryDevice, Keyboard.Modifiers), out targetElement); 7129(Keyboard.Modifiers & ModifierKeys.Shift) != ModifierKeys.Shift); 7174if ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift)
src\Framework\System\Windows\Controls\DataGridCell.cs (1)
901bool isCtrlKeyPressed = (Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control;
src\Framework\System\Windows\Controls\DataGridCheckBoxColumn.cs (1)
210keyArgs.RoutedEvent == Keyboard.KeyDownEvent &&
src\Framework\System\Windows\Controls\DataGridComboBoxColumn.cs (1)
604if ((keyArgs != null) && keyArgs.RoutedEvent == Keyboard.KeyDownEvent && ((keyArgs.KeyStates & KeyStates.Down) == KeyStates.Down))
src\Framework\System\Windows\Controls\DataGridHyperlinkColumn.cs (1)
295Debug.Assert(e.RoutedEvent == Keyboard.PreviewKeyDownEvent, "We should only reach here on the PreviewKeyDown event because the TextBox within is expected to handle the preview event and hence trump the successive KeyDown event.");
src\Framework\System\Windows\Controls\DataGridTextColumn.cs (1)
273Debug.Assert(e.RoutedEvent == Keyboard.PreviewKeyDownEvent, "We should only reach here on the PreviewKeyDown event because the TextBox within is expected to handle the preview event and hence trump the successive KeyDown event.");
src\Framework\System\Windows\Controls\DatePicker.cs (1)
1154if ((Keyboard.Modifiers & ModifierKeys.Alt) == ModifierKeys.Alt)
src\Framework\System\Windows\Controls\DocumentViewer.cs (2)
1303if (Keyboard.IsKeyDown(Key.LeftCtrl) || 1304Keyboard.IsKeyDown(Key.RightCtrl))
src\Framework\System\Windows\Controls\FlowDocumentReader.cs (3)
65EventManager.RegisterClassHandler(typeof(FlowDocumentReader), Keyboard.KeyDownEvent, new KeyEventHandler(KeyDownHandler), true); 939focusedElement = Keyboard.FocusedElement as DependencyObject; 996DependencyObject focusedElement = Keyboard.FocusedElement as DependencyObject;
src\Framework\System\Windows\Controls\FlowDocumentScrollViewer.cs (2)
71EventManager.RegisterClassHandler(typeof(FlowDocumentScrollViewer), Keyboard.KeyDownEvent, new KeyEventHandler(KeyDownHandler), true); 713if ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control)
src\Framework\System\Windows\Controls\ItemsControl.cs (8)
67EventManager.RegisterClassHandler(typeof(ItemsControl), Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnGotFocus)); 1875DependencyObject startingElement = Keyboard.FocusedElement as DependencyObject; 2225return NavigateByPage(FocusedInfo, Keyboard.FocusedElement as FrameworkElement, direction, itemNavigateArgs); 2617if (container == null || Keyboard.IsFocusable(container)) 3311NavigateByLine(startingInfo, FocusNavigationDirection.Up, new ItemNavigateArgs(Mouse.PrimaryDevice, Keyboard.Modifiers)); 3316NavigateByLine(startingInfo, FocusNavigationDirection.Down, new ItemNavigateArgs(Mouse.PrimaryDevice, Keyboard.Modifiers)); 3331NavigateByLine(startingInfo, direction, new ItemNavigateArgs(Mouse.PrimaryDevice, Keyboard.Modifiers)); 3341NavigateByLine(startingInfo, direction, new ItemNavigateArgs(Mouse.PrimaryDevice, Keyboard.Modifiers));
src\Framework\System\Windows\Controls\ListBox.cs (24)
78EventManager.RegisterClassHandler(typeof(ListBox), Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnGotKeyboardFocus)); 320if (((Keyboard.Modifiers & ModifierKeys.Control) == (ModifierKeys.Control)) && (SelectionMode == SelectionMode.Extended)) 333if (((Keyboard.Modifiers & ModifierKeys.Control) == (ModifierKeys.Control)) && (SelectionMode == SelectionMode.Extended)) 376new ItemNavigateArgs(e.Device, Keyboard.Modifiers))) 390NavigateToStart(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 394NavigateToEnd(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 410if ((Keyboard.Modifiers & (ModifierKeys.Control|ModifierKeys.Alt)) == ModifierKeys.Alt) 418if (IsTextSearchEnabled && Keyboard.Modifiers == ModifierKeys.None) 435if ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control) 451if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Shift)) == ModifierKeys.Control) 456else if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Shift)) == ModifierKeys.Shift) 461else if ((Keyboard.Modifiers & ModifierKeys.Shift) == 0) 481NavigateByPage(FocusNavigationDirection.Up, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 485NavigateByPage(FocusNavigationDirection.Down, new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 673else if ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control) 690if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Shift)) == (ModifierKeys.Control | ModifierKeys.Shift)) 694else if ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control) 698else if ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift) 712if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Shift)) == 0) 729NavigateToItem(ItemInfoFromContainer(listItem), new ItemNavigateArgs(Mouse.PrimaryDevice, Keyboard.Modifiers)); 878if ((Keyboard.Modifiers & ModifierKeys.Control) == 0) 889if ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift) 891bool clearCurrentSelection = (Keyboard.Modifiers & ModifierKeys.Control) == 0; 894else if ((Keyboard.Modifiers & ModifierKeys.Control) == 0)
src\Framework\System\Windows\Controls\Menu.cs (2)
352if (!(Keyboard.IsKeyDown(Key.LeftAlt) || Keyboard.IsKeyDown(Key.RightAlt)))
src\Framework\System\Windows\Controls\MenuItem.cs (10)
1954if ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift) 1956NavigateToEnd(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 1960NavigateToStart(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 2003NavigateToStart(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 2013NavigateToEnd(new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 2402NavigateToStart(new ItemNavigateArgs(Keyboard.PrimaryDevice, Keyboard.Modifiers)); 2437object previousFocus = Keyboard.FocusedElement; 2438parent.NavigateByLine(parent.FocusedInfo, KeyboardNavigation.KeyToTraversalDirection(key), new ItemNavigateArgs(Keyboard.PrimaryDevice, modifiers)); 2439object currentFocus = Keyboard.FocusedElement;
src\Framework\System\Windows\Controls\PopupControlService.cs (6)
137else if (e.StagingItem.Input.RoutedEvent == Keyboard.KeyDownEvent) 141else if (e.StagingItem.Input.RoutedEvent == Keyboard.KeyUpEvent) 216(e.SystemKey == Key.F10) && ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift) && ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control)) 220else if ((e.SystemKey == Key.F10) && ((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift)) 240IInputElement focusedElement = Keyboard.FocusedElement;
src\Framework\System\Windows\Controls\Primitives\ButtonBase.cs (3)
529Keyboard.Focus(null); 604if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Alt)) != ModifierKeys.Alt) 668if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Alt)) != ModifierKeys.Alt)
src\Framework\System\Windows\Controls\Primitives\MenuBase.cs (4)
68EventManager.RegisterClassHandler(typeof(MenuBase), Keyboard.PreviewKeyboardInputProviderAcquireFocusEvent, new KeyboardInputProviderAcquireFocusEventHandler(OnPreviewKeyboardInputProviderAcquireFocus), true); 69EventManager.RegisterClassHandler(typeof(MenuBase), Keyboard.KeyboardInputProviderAcquireFocusEvent, new KeyboardInputProviderAcquireFocusEventHandler(OnKeyboardInputProviderAcquireFocus), true); 681 Keyboard.Focus(null); 692Keyboard.ClearFocus();
src\Framework\System\Windows\Controls\Primitives\ScrollBar.cs (1)
157((Keyboard.Modifiers & ModifierKeys.Shift) == ModifierKeys.Shift))
src\Framework\System\Windows\Controls\Primitives\Selector.cs (1)
1344DependencyObject currentFocus = Keyboard.FocusedElement as DependencyObject;
src\Framework\System\Windows\Controls\Primitives\TextBoxBase.cs (1)
2217if (Keyboard.FocusedElement == textBox)
src\Framework\System\Windows\Controls\ScrollViewer.cs (1)
981DependencyObject focusedElement = Keyboard.FocusedElement as DependencyObject;
src\Framework\System\Windows\Controls\SinglePageViewer.cs (2)
68EventManager.RegisterClassHandler(typeof(FlowDocumentPageViewer), Keyboard.KeyDownEvent, new KeyEventHandler(KeyDownHandler), true); 433if ((Keyboard.Modifiers & ModifierKeys.Control) == ModifierKeys.Control)
src\Framework\System\Windows\Controls\Slider.cs (1)
187if (keyEventArgs != null && slider != null && Keyboard.Modifiers == ModifierKeys.None)
src\Framework\System\Windows\Controls\StickyNote.cs (2)
576ContextMenu menu = Keyboard.FocusedElement as ContextMenu; 1411Keyboard.Focus(null);
src\Framework\System\Windows\Controls\TabItem.cs (3)
303if (e.OldFocus != Keyboard.FocusedElement) 336if (e.OldFocus != Keyboard.FocusedElement) 473TabItem currentFocus = Keyboard.FocusedElement as TabItem;
src\Framework\System\Windows\Controls\TextSearch.cs (1)
253_attachedTo.NavigateToItem(matchedItem, matchedItemIndex, new ItemsControl.ItemNavigateArgs(Keyboard.PrimaryDevice, ModifierKeys.None));
src\Framework\System\Windows\Controls\ToolBar.cs (2)
268Keyboard.Focus(null); 682Keyboard.Focus(null);
src\Framework\System\Windows\Controls\TreeView.cs (9)
604return ((Keyboard.Modifiers & ModifierKeys.Control) == (ModifierKeys.Control)); 612return ((Keyboard.Modifiers & ModifierKeys.Shift) == (ModifierKeys.Shift)); 619return NavigateToStartInternal(new ItemNavigateArgs(Keyboard.PrimaryDevice, Keyboard.Modifiers), true /*shouldFocus*/, out container); 626return NavigateToEndInternal(new ItemNavigateArgs(Keyboard.PrimaryDevice, Keyboard.Modifiers), true /*shouldFocus*/, out container); 707IInputElement originalFocusedElement = Keyboard.FocusedElement; 722new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 762DependencyObject currentFocus = Keyboard.FocusedElement as DependencyObject;
src\Framework\System\Windows\Controls\TreeViewItem.cs (4)
657return ((Keyboard.Modifiers & ModifierKeys.Control) == (ModifierKeys.Control)); 685IInputElement originalFocus = Keyboard.FocusedElement; 702new ItemNavigateArgs(e.Device, Keyboard.Modifiers)); 716DependencyObject currentFocus = Keyboard.FocusedElement as DependencyObject;
src\Framework\System\Windows\Documents\Hyperlink.cs (2)
499if (IsEnabled && (!IsEditable || ((Keyboard.Modifiers & ModifierKeys.Control) != 0))) 852if ((Keyboard.Modifiers & ModifierKeys.Control) == 0)
src\Framework\System\windows\Documents\TextEditor.cs (2)
413EventManager.RegisterClassHandler(controlType, Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnGotKeyboardFocus)); 414EventManager.RegisterClassHandler(controlType, Keyboard.LostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnLostKeyboardFocus));
src\Framework\System\windows\Documents\TextEditorMouse.cs (4)
117else if (clickCount == 2 && (Keyboard.Modifiers & ModifierKeys.Shift) == 0 && This.Selection.IsEmpty) 124else if (clickCount == 3 && (Keyboard.Modifiers & ModifierKeys.Shift) == 0) 202if (This.UiScope != Keyboard.FocusedElement) 652return This.UiScope == Keyboard.FocusedElement &&
src\Framework\System\windows\Documents\TextEditorTyping.cs (3)
67EventManager.RegisterClassHandler(controlType, Keyboard.PreviewKeyDownEvent, new KeyEventHandler(OnPreviewKeyDown)); 68EventManager.RegisterClassHandler(controlType, Keyboard.KeyDownEvent, new KeyEventHandler(OnKeyDown)); 69EventManager.RegisterClassHandler(controlType, Keyboard.KeyUpEvent, new KeyEventHandler(OnKeyUp));
src\Framework\System\windows\Documents\TextSelection.cs (3)
801if ((Keyboard.Modifiers & ModifierKeys.Shift) != 0) 911bool disableWordExpansion = _textEditor.AutoWordSelection == false || ((Keyboard.Modifiers & ModifierKeys.Shift) != 0 && (Keyboard.Modifiers & ModifierKeys.Control) != 0);
src\Framework\System\Windows\Documents\TextStore.cs (3)
1074if (Keyboard.FocusedElement == UiScope) 2903if ((Keyboard.Modifiers & ModifierKeys.Shift) != 0) 2907if ((Keyboard.Modifiers & ModifierKeys.Control) != 0)
src\Framework\System\Windows\FrameworkContentElement.cs (2)
110EventManager.RegisterClassHandler(typeof(FrameworkContentElement), Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnGotKeyboardFocus)); 111EventManager.RegisterClassHandler(typeof(FrameworkContentElement), Keyboard.LostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnLostKeyboardFocus));
src\Framework\System\Windows\FrameworkElement.cs (7)
2387EventManager.RegisterClassHandler(_typeofThis, Keyboard.PreviewGotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnPreviewGotKeyboardFocus)); 2388EventManager.RegisterClassHandler(_typeofThis, Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnGotKeyboardFocus)); 2389EventManager.RegisterClassHandler(_typeofThis, Keyboard.LostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnLostKeyboardFocus)); 5344if (activeElement != null && activeElement != sender && Keyboard.IsFocusable(activeElement as DependencyObject)) 5346IInputElement oldFocus = Keyboard.FocusedElement; 5349if (Keyboard.FocusedElement == activeElement || Keyboard.FocusedElement != oldFocus)
src\Framework\System\Windows\Input\KeyboardNavigation.cs (13)
893Current.ShowFocusVisual(Keyboard.FocusedElement as DependencyObject); 1030return Navigate(currentElement, request, Keyboard.Modifiers); 1272if(inputEventArgs.RoutedEvent != Keyboard.KeyDownEvent) 2824sourceUIElement.RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(_LostFocus)); 2829sourceContentElement.RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(_LostFocus)); 2841targetContentElement.AddHandler(Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(_LostFocus), true); 2853targetUIElement.AddHandler(Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(_LostFocus), true); 2882((UIElement)sender).RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(_LostFocus)); 2884((ContentElement)sender).RemoveHandler(Keyboard.PreviewLostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(_LostFocus)); 3259if (inputEventArgs.RoutedEvent == Keyboard.LostKeyboardFocusEvent) 3270else if (inputEventArgs.RoutedEvent == Keyboard.KeyDownEvent) 3282if ((Keyboard.Modifiers & (ModifierKeys.Control | ModifierKeys.Shift | ModifierKeys.Windows)) == ModifierKeys.None) 3301else if (inputEventArgs.RoutedEvent == Keyboard.KeyUpEvent)
src\Framework\System\Windows\Interop\ActiveXHost.cs (2)
95EventManager.RegisterClassHandler(typeof(ActiveXHost), Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnGotFocus)); 96EventManager.RegisterClassHandler(typeof(ActiveXHost), Keyboard.LostKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(OnLostFocus));
src\Framework\System\Windows\Navigation\NavigationService.cs (1)
966Keyboard.PrimaryDevice.Focus(null);
System.Activities.Core.Presentation (22)
System\Activities\Core\Presentation\CaseDesigner.xaml.cs (3)
59Keyboard.Focus((IInputElement)this); 108Keyboard.Focus(this); 116Keyboard.Focus(this);
System\Activities\Core\Presentation\CaseKeyBox.xaml.cs (1)
200Keyboard.Focus((IInputElement)this.visibleBox);
System\Activities\Core\Presentation\CatchDesigner.xaml.cs (2)
97Keyboard.Focus(this); 105Keyboard.Focus(this);
System\Activities\Core\Presentation\FlowchartDesigner.Container.cs (1)
378Keyboard.Focus(modelItemsToSelect[0].View as IInputElement);
System\Activities\Core\Presentation\FlowchartDesigner.xaml.cs (1)
1727Keyboard.Focus(view);
System\Activities\Core\Presentation\FlowSwitchDesigner.xaml.cs (1)
204Keyboard.ClearFocus();
System\Activities\Core\Presentation\StateContainerEditor.CompositeView.cs (1)
410Keyboard.Focus(modelItemsPasted[0].View as IInputElement);
System\Activities\Core\Presentation\StateContainerEditor.xaml.cs (2)
1472Keyboard.Focus(VirtualizedContainerService.TryGetVirtualizedElement(this.activeSrcConnectionPoint.ParentDesigner)); 2010Keyboard.Focus((IInputElement)modelItem.View);
System\Activities\Core\Presentation\StateContainerResizeGrip.cs (1)
112Keyboard.Focus(designer);
System\Activities\Core\Presentation\SwitchDesigner.xaml.cs (2)
321Keyboard.Focus((IInputElement)sender); 327Keyboard.Focus((IInputElement)sender);
System\Activities\Core\Presentation\TryCatchDesigner.xaml.cs (5)
362Keyboard.Focus((IInputElement)sender); 368Keyboard.Focus((IInputElement)sender); 399Keyboard.Focus((IInputElement)sender); 405Keyboard.Focus((IInputElement)sender); 519Keyboard.Focus((IInputElement)this);
System\ServiceModel\Activities\Presentation\ContentCorrelationTypeExpander.xaml.cs (1)
183if (null != item && item.IsSelected && item.IsSelectionActive && Key.Enter == e.Key && Keyboard.Modifiers == ModifierKeys.None)
System\ServiceModel\Activities\Presentation\MessageQueryEditor.xaml.cs (1)
92if (e.Key == Key.Enter && Keyboard.Modifiers == ModifierKeys.None)
System.Activities.Presentation (66)
System.Activities.Presentation\System\Activities\Presentation\ActivityDesigner.cs (1)
251Keyboard.Focus(this.defaultDisplayNameBox);
System.Activities.Presentation\System\Activities\Presentation\Annotations\FloatingAnnotationView.xaml.cs (1)
82Keyboard.Focus(this.annotationTextBox);
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\CategoryList.cs (1)
764Keyboard.FocusedElement,
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\FromExpression\Framework\UserInterface\FocusScopeManager.cs (5)
62EventManager.RegisterClassHandler(typeof(Window), Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(FocusScopeManager.HandleGotKeyboardFocusEvent), true); 63EventManager.RegisterClassHandler(typeof(Popup), Keyboard.GotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(FocusScopeManager.HandleGotKeyboardFocusEvent), true); 65EventManager.RegisterClassHandler(typeof(Window), Keyboard.PreviewGotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(FocusScopeManager.HandlePreviewGotKeyboardFocus), true); 66EventManager.RegisterClassHandler(typeof(Popup), Keyboard.PreviewGotKeyboardFocusEvent, new KeyboardFocusChangedEventHandler(FocusScopeManager.HandlePreviewGotKeyboardFocus), true); 444Keyboard.Focus(null);
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\FromExpression\Framework\ValueEditors\ChoiceEditor.cs (1)
989Keyboard.Focus(null);
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\FromExpression\Framework\ValueEditors\StringEditor.cs (1)
367Keyboard.Focus(null);
System.Activities.Presentation\System\Activities\Presentation\Base\Core\Internal\PropertyEditing\Selection\PropertySelection.cs (2)
407if (Keyboard.Modifiers == ModifierKeys.Control) 430if (focusable != null && focusable == Keyboard.Focus(focusable))
System.Activities.Presentation\System\Activities\Presentation\CutCopyPasteHelper.cs (1)
526pasteContainer = Keyboard.FocusedElement as ICompositeView;
System.Activities.Presentation\System\Activities\Presentation\DefaultCommandExtensionCallback.cs (3)
177else if (keyArgs.Key == this.chordKey && (Keyboard.Modifiers == ModifierKeys.None || Keyboard.Modifiers == ModifierKeys.Control)) 190else if (Keyboard.Modifiers != ModifierKeys.Control)
System.Activities.Presentation\System\Activities\Presentation\FreeFormEditing\ConnectorEditor.cs (1)
616Keyboard.Focus(adornedEditor.Connector);
System.Activities.Presentation\System\Activities\Presentation\Model\ModelItemExtensions.cs (1)
975Keyboard.Focus(this.itemToFocus.View as IInputElement);
System.Activities.Presentation\System\Activities\Presentation\View\DataGridHelper.cs (6)
673if ((Keyboard.IsKeyDown(Key.RightShift)) || (Keyboard.IsKeyDown(Key.LeftShift)) || 674(Keyboard.IsKeyDown(Key.LeftCtrl)) || (Keyboard.IsKeyDown(Key.RightCtrl))) 1540var currentFocus = (UIElement)Keyboard.FocusedElement; 1552Keyboard.Focus(currentFocus);
System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.Commands.cs (5)
1175UIElement focusedElement = Keyboard.FocusedElement as UIElement; 1192WorkflowViewElement focusedElement = Keyboard.FocusedElement as WorkflowViewElement; 1269Keyboard.Focus(designer); 1275Keyboard.Focus(this.GetDesignerToFocus()); 1394Keyboard.Focus(target);
System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.xaml.cs (9)
596WorkflowViewElement focusedElement = Keyboard.FocusedElement as WorkflowViewElement; 709if (!e.Handled && Keyboard.Modifiers == ModifierKeys.None && e.OriginalSource is WorkflowViewElement) 727if (Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl)) 839if (Keyboard.Modifiers == ModifierKeys.Control) 921if ((null != keyArgs && keyArgs.Key == Key.Enter && Keyboard.Modifiers == ModifierKeys.None) || null != mouseArgs) 938if (null != breadcrumbItems && breadcrumbItems.Items.Count > 0 && Keyboard.Modifiers == ModifierKeys.None && (e.Key == Key.Left || e.Key == Key.Right)) 994DependencyObject focusedElement = Keyboard.FocusedElement as DependencyObject; 998Keyboard.Focus(this.GetDesignerToFocus());
System.Activities.Presentation\System\Activities\Presentation\View\RubberBandSelector.cs (3)
153this.Select(Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl)); 296Keyboard.Focus(selectedModelItems[0].View as IInputElement);
System.Activities.Presentation\System\Activities\Presentation\View\ScrollViewerPanner.cs (1)
270|| (Keyboard.IsKeyDown(Key.Space) && this.CurrentPanState == PanState.Panning))
System.Activities.Presentation\System\Activities\Presentation\View\TypePresenter.xaml.cs (2)
235Keyboard.Focus(this.typeTextBlock); 242Keyboard.Focus(this.typeComboBox);
System.Activities.Presentation\System\Activities\Presentation\View\VisualBasicEditor.xaml.cs (1)
406Keyboard.Focus(textBlock);
System.Activities.Presentation\System\Activities\Presentation\WorkflowItemPresenter.cs (5)
442Keyboard.Focus((UIElement)this.Item.View); 457Keyboard.Focus(view); 635if (Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl)) 647Keyboard.Focus((FrameworkElement)this);
System.Activities.Presentation\System\Activities\Presentation\WorkflowItemsPresenter.cs (4)
262Keyboard.Focus(view); 520if (Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl)) 530Keyboard.Focus((FrameworkElement)sender);
System.Activities.Presentation\System\Activities\Presentation\WorkflowViewElement.cs (12)
600if (!Keyboard.IsKeyDown(Key.LeftCtrl) && !Keyboard.IsKeyDown(Key.RightCtrl)) 609shouldSetFocus = Keyboard.FocusedElement != this; 627if (!Keyboard.IsKeyDown(Key.LeftCtrl) && !Keyboard.IsKeyDown(Key.RightCtrl)) 629shouldSetFocus = Keyboard.FocusedElement != this; 652Keyboard.Focus(this); 766if (Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl)) 825if (Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl)) 1029Keyboard.Focus(viewToFocus);