85 references to FocusedElement
PresentationCore (29)
MS\Internal\Automation\ElementProxy.cs (1)
357
AutomationPeer focusedPeer = AutomationPeer.AutomationPeerFromInputElement(Keyboard.
FocusedElement
);
MS\Internal\Interop\TipTsfHelper.cs (1)
81
if (Keyboard.
FocusedElement
== focusedObject)
System\Windows\ContentElement.cs (1)
480
return (Keyboard.
FocusedElement
== this);
System\Windows\Input\Command\CommandDevice.cs (2)
40
return Keyboard.
FocusedElement
;
289
return Keyboard.
FocusedElement
;
System\Windows\Input\Command\RoutedCommand.cs (5)
93
Execute(parameter, FilterInputElement(Keyboard.
FocusedElement
));
104
return CanExecuteImpl(parameter, FilterInputElement(Keyboard.
FocusedElement
), false, out unused);
139
target = FilterInputElement(Keyboard.
FocusedElement
);
175
target = FilterInputElement(Keyboard.
FocusedElement
);
375
target = FilterInputElement(Keyboard.
FocusedElement
);
System\Windows\Input\DefaultTextStore.cs (2)
150
_composition = new DefaultTextStoreTextComposition(InputManager.Current, Keyboard.
FocusedElement
, result, TextCompositionAutoComplete.On);
180
_composition = new DefaultTextStoreTextComposition(InputManager.Current, Keyboard.
FocusedElement
, "", TextCompositionAutoComplete.Off);
System\Windows\Input\FocusManager.cs (2)
231
DependencyObject oldFocus = Keyboard.
FocusedElement
as DependencyObject;
233
DependencyObject newFocus = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Input\InputMethod.cs (8)
550
IntPtr hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
587
hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
783
IntPtr hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
834
hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
1041
IntPtr hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
1115
IntPtr hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
1307
if (inputElement == Keyboard.
FocusedElement
)
1341
hwnd = HwndFromInputElement(Keyboard.
FocusedElement
);
System\Windows\Input\TextServicesManager.cs (2)
139
DependencyObject element = Keyboard.
FocusedElement
as DependencyObject;
175
DependencyObject element = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\InterOp\HwndKeyboardInputProvider.cs (2)
353
DependencyObject focusedDO = Keyboard.
FocusedElement
as DependencyObject;
502
restoreFocusDO = (DependencyObject)Keyboard.
FocusedElement
;
System\Windows\InterOp\HwndSource.cs (1)
2082
DependencyObject focusObject = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\UIElement.cs (1)
2593
return (Keyboard.
FocusedElement
== this);
System\Windows\UIElement3D.cs (1)
574
return (Keyboard.
FocusedElement
== this);
PresentationFramework (42)
MS\Internal\Documents\DocumentViewerHelper.cs (1)
342
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Controls\Button.cs (3)
97
b.UpdateIsDefaulted(Keyboard.
FocusedElement
);
115
b.UpdateIsDefaulted(Keyboard.
FocusedElement
);
199
UpdateIsDefaulted(Keyboard.
FocusedElement
);
System\Windows\Controls\ComboBox.cs (1)
1141
DependencyObject currentFocus = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Controls\ContextMenu.cs (2)
606
if (Keyboard.
FocusedElement
!= null)
608
_weakRefToPreviousFocus = new WeakReference<IInputElement>(Keyboard.
FocusedElement
);
System\Windows\Controls\DataGrid.cs (8)
5588
UIElement startElement = Keyboard.
FocusedElement
as UIElement;
5589
ContentElement startContentElement = (startElement == null) ? Keyboard.
FocusedElement
as ContentElement : null;
5878
FrameworkElement startingElement = Keyboard.
FocusedElement
as FrameworkElement;
5922
UIElement startElement = Keyboard.
FocusedElement
as UIElement;
5923
ContentElement startContentElement = (startElement == null) ? Keyboard.
FocusedElement
as ContentElement : null;
5936
if (wasEditing && previous && Keyboard.
FocusedElement
== currentCellContainer)
6031
DataGridCell newCell = Keyboard.
FocusedElement
as DataGridCell;
6182
startingElement = Keyboard.
FocusedElement
as FrameworkElement;
System\Windows\Controls\FlowDocumentReader.cs (2)
933
focusedElement = Keyboard.
FocusedElement
as DependencyObject;
990
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Controls\ItemsControl.cs (2)
1872
DependencyObject startingElement = Keyboard.
FocusedElement
as DependencyObject;
2222
return NavigateByPage(FocusedInfo, Keyboard.
FocusedElement
as FrameworkElement, direction, itemNavigateArgs);
System\Windows\Controls\MenuItem.cs (2)
2377
object previousFocus = Keyboard.
FocusedElement
;
2379
object currentFocus = Keyboard.
FocusedElement
;
System\Windows\Controls\PopupControlService.cs (1)
276
DependencyObject owner = FindToolTipOwner(Keyboard.
FocusedElement
, ToolTipService.TriggerAction.KeyboardShortcut);
System\Windows\Controls\Primitives\Selector.cs (1)
1326
DependencyObject currentFocus = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Controls\Primitives\TextBoxBase.cs (1)
2181
if (Keyboard.
FocusedElement
== textBox)
System\Windows\Controls\ScrollViewer.cs (1)
954
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Controls\StickyNote.cs (1)
566
ContextMenu menu = Keyboard.
FocusedElement
as ContextMenu;
System\Windows\Controls\TabItem.cs (5)
302
if (e.OldFocus != Keyboard.
FocusedElement
)
335
if (e.OldFocus != Keyboard.
FocusedElement
)
361
if (Keyboard.
FocusedElement
is DependencyObject focusedElement)
364
if (thisFocusScope != null && Keyboard.
FocusedElement
is DependencyObject currentFocus)
487
TabItem currentFocus = Keyboard.
FocusedElement
as TabItem;
System\Windows\Controls\TreeView.cs (2)
705
IInputElement originalFocusedElement = Keyboard.
FocusedElement
;
760
DependencyObject currentFocus = Keyboard.
FocusedElement
as DependencyObject;
System\Windows\Controls\TreeViewItem.cs (2)
684
IInputElement originalFocus = Keyboard.
FocusedElement
;
715
DependencyObject currentFocus = Keyboard.
FocusedElement
as DependencyObject;
System\windows\Documents\TextEditorMouse.cs (2)
200
if (This.UiScope != Keyboard.
FocusedElement
)
651
return This.UiScope == Keyboard.
FocusedElement
&&
System\Windows\Documents\TextStore.cs (1)
1206
if (Keyboard.
FocusedElement
== UiScope)
System\Windows\FrameworkElement.cs (3)
5348
IInputElement oldFocus = Keyboard.
FocusedElement
;
5351
if (Keyboard.
FocusedElement
== activeElement || Keyboard.
FocusedElement
!= oldFocus)
System\Windows\Input\KeyboardNavigation.cs (1)
840
Current.ShowFocusVisual(Keyboard.
FocusedElement
as DependencyObject);
System.Windows.Controls.Ribbon (14)
Microsoft\Windows\Controls\KeyTipService.cs (2)
949
object oldFocusedElement = Keyboard.
FocusedElement
;
962
object newFocusedElement = Keyboard.
FocusedElement
;
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (4)
2000
RibbonGroup ribbonGroup = TreeHelper.FindVisualAncestor<RibbonGroup>(Keyboard.
FocusedElement
as DependencyObject);
2074
RibbonControl ribbonControl = TreeHelper.FindVisualAncestor<RibbonControl>(Keyboard.
FocusedElement
as DependencyObject);
2106
!TreeHelper.IsVisualAncestorOf(targetControl, Keyboard.
FocusedElement
as DependencyObject))
2245
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
Microsoft\Windows\Controls\Ribbon\RibbonComboBox.cs (2)
1198
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
1446
RibbonGalleryItem focusedGalleryItem = Keyboard.
FocusedElement
as RibbonGalleryItem;
Microsoft\Windows\Controls\Ribbon\RibbonGallery.cs (1)
2674
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
Microsoft\Windows\Controls\Ribbon\RibbonHelper.cs (2)
482
UIElement uie = Keyboard.
FocusedElement
as UIElement;
487
ContentElement ce = Keyboard.
FocusedElement
as ContentElement;
Microsoft\Windows\Controls\Ribbon\RibbonMenuButton.cs (1)
807
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
Microsoft\Windows\Controls\Ribbon\RibbonTab.cs (1)
378
DependencyObject focusedElement = Keyboard.
FocusedElement
as DependencyObject;
Microsoft\Windows\Controls\Ribbon\RibbonTabHeader.cs (1)
535
if (!((bool)e.NewValue) && Keyboard.
FocusedElement
== d)