/// <summary> /// Initializes static members of the <see cref="AutoHideRootControl"/> class. /// </summary> static AutoHideRootControl() { DefaultStyleKeyProperty.OverrideMetadata(typeof(AutoHideRootControl), new FrameworkPropertyMetadata(typeof(AutoHideRootControl))); FocusableProperty.OverrideMetadata(typeof(AutoHideRootControl), new FrameworkPropertyMetadata(BooleanBoxes.False)); IsTabStopProperty.OverrideMetadata(typeof(AutoHideRootControl), new FrameworkPropertyMetadata(BooleanBoxes.False)); }
static TransitionFrame() { DefaultStyleKeyProperty.OverrideMetadata(typeof(TransitionFrame), new FrameworkPropertyMetadata(typeof(TransitionFrame))); NavigationUIVisibilityProperty.OverrideMetadata(typeof(TransitionFrame), new FrameworkPropertyMetadata(NavigationUIVisibility.Hidden)); IsTabStopProperty.OverrideMetadata(typeof(TransitionFrame), new FrameworkPropertyMetadata(false)); FocusVisualStyleProperty.OverrideMetadata(typeof(TransitionFrame), new FrameworkPropertyMetadata(null)); }
static GroupBox() { FocusableProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(false)); IsTabStopProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(false)); DefaultStyleKeyProperty.OverrideMetadata(typeof(GroupBox), new FrameworkPropertyMetadata(typeof(GroupBox))); EventManager.RegisterClassHandler(typeof(GroupBox), AccessKeyManager.AccessKeyPressedEvent, new AccessKeyPressedEventHandler(OnAccessKeyPressed)); }
static ApplicationBar() { DefaultStyleKeyProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(typeof(ApplicationBar))); var itemsPanelTemplate = new ItemsPanelTemplate(new FrameworkElementFactory(typeof(ApplicationBarPanel))); itemsPanelTemplate.Seal(); ItemsPanelProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(itemsPanelTemplate)); IsTabStopProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(false)); FocusableProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(false)); FocusManager.IsFocusScopeProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(true)); KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata( typeof(ApplicationBar), new FrameworkPropertyMetadata(KeyboardNavigationMode.Cycle)); KeyboardNavigation.TabNavigationProperty.OverrideMetadata( typeof(ApplicationBar), new FrameworkPropertyMetadata(KeyboardNavigationMode.Cycle)); KeyboardNavigation.ControlTabNavigationProperty.OverrideMetadata( typeof(ApplicationBar), new FrameworkPropertyMetadata(KeyboardNavigationMode.Once)); HorizontalAlignmentProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(HorizontalAlignment.Stretch)); VerticalAlignmentProperty.OverrideMetadata(typeof(ApplicationBar), new FrameworkPropertyMetadata(VerticalAlignment.Bottom)); EventManager.RegisterClassHandler(typeof(ApplicationBar), Mouse.LostMouseCaptureEvent, new MouseEventHandler(OnLostMouseCapture)); EventManager.RegisterClassHandler(typeof(ApplicationBar), Mouse.PreviewMouseUpOutsideCapturedElementEvent, new MouseButtonEventHandler(OnPreviewMouseButtonOutsideCapturedElement)); }
/// <summary> /// Ctor /// </summary> static FXMonthView() { DefaultStyleKeyProperty.OverrideMetadata(typeof(FXMonthView), new FrameworkPropertyMetadata(typeof(FXMonthView))); IsTabStopProperty.OverrideMetadata(typeof(FXMonthView), new FrameworkPropertyMetadata(false)); themeList = new Dictionary <string, ResourceDictionary>(4); PreloadThemes(); }
static ThemeAwareFrame() { NavigationUIVisibilityProperty.OverrideMetadata(typeof(ThemeAwareFrame), new FrameworkPropertyMetadata(NavigationUIVisibility.Hidden)); IsTabStopProperty.OverrideMetadata(typeof(ThemeAwareFrame), new FrameworkPropertyMetadata(false)); FocusableProperty.OverrideMetadata(typeof(ThemeAwareFrame), new FrameworkPropertyMetadata(false)); FocusVisualStyleProperty.OverrideMetadata(typeof(ThemeAwareFrame), new FrameworkPropertyMetadata(null)); }
static DateTimeComponentSelector() { DefaultStyleKeyProperty.OverrideMetadata(typeof(DateTimeComponentSelector), new FrameworkPropertyMetadata(typeof(DateTimeComponentSelector))); IsTabStopProperty.OverrideMetadata(typeof(DateTimeComponentSelector), new FrameworkPropertyMetadata(true)); KeyboardNavigation.TabNavigationProperty.OverrideMetadata(typeof(DateTimeComponentSelector), new FrameworkPropertyMetadata(KeyboardNavigationMode.Cycle)); }
static AeroWizardHeader() { DefaultStyleKeyProperty.OverrideMetadata(typeof(AeroWizardHeader), new FrameworkPropertyMetadata(typeof(AeroWizardHeader))); IsTabStopProperty.OverrideMetadata(typeof(AeroWizardHeader), new FrameworkPropertyMetadata(false)); }
static Submenu() { DefaultStyleKeyProperty.OverrideMetadata(typeof(Submenu), new FrameworkPropertyMetadata(typeof(Submenu))); IsTabStopProperty.OverrideMetadata(typeof(Submenu), new FrameworkPropertyMetadata(false)); KeyboardNavigation.TabNavigationProperty.OverrideMetadata(typeof(Submenu), new FrameworkPropertyMetadata(KeyboardNavigationMode.Cycle)); KeyboardNavigation.ControlTabNavigationProperty.OverrideMetadata(typeof(Submenu), new FrameworkPropertyMetadata(KeyboardNavigationMode.Contained)); KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata(typeof(Submenu), new FrameworkPropertyMetadata(KeyboardNavigationMode.Cycle)); }
static StatusBarItem() { DefaultStyleKeyProperty.OverrideMetadata(typeof(StatusBarItem), new FrameworkPropertyMetadata(typeof(StatusBarItem))); _dType = DependencyObjectType.FromSystemTypeInternal(typeof(StatusBarItem)); IsTabStopProperty.OverrideMetadata(typeof(StatusBarItem), new FrameworkPropertyMetadata(BooleanBoxes.FalseBox)); AutomationProperties.IsOffscreenBehaviorProperty.OverrideMetadata(typeof(StatusBarItem), new FrameworkPropertyMetadata(IsOffscreenBehavior.FromClip)); }
static GroupSeparatorMenuItem() { var type = typeof(GroupSeparatorMenuItem); DefaultStyleKeyProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(type)); IsEnabledProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(BooleanBoxes.FalseBox, null, CoerceIsEnabledAndTabStop)); IsTabStopProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(BooleanBoxes.FalseBox, null, CoerceIsEnabledAndTabStop)); }
/// <summary> /// Initializes the <see cref="InlineModalDialog"/> class. /// </summary> static InlineModalDialog() { DefaultStyleKeyProperty.OverrideMetadata(typeof(InlineModalDialog), new FrameworkPropertyMetadata(typeof(InlineModalDialog))); IsTabStopProperty.OverrideMetadata(typeof(InlineModalDialog), new FrameworkPropertyMetadata(false.Box())); CommandManager.RegisterClassCommandBinding(typeof(InlineModalDialog), new CommandBinding(CloseCommand, (sender, args) => ((InlineModalDialog)sender).HandleCloseCommand(args))); }
static XamlImage() { DefaultStyleKeyProperty.OverrideMetadata(typeof(XamlImage), new FrameworkPropertyMetadata(typeof(XamlImage))); IsTabStopProperty.OverrideMetadata(typeof(XamlImage), new FrameworkPropertyMetadata(false)); }
static RadSplitButton() { IsTabStopProperty.OverrideMetadata(typeof(RadSplitButton), new FrameworkPropertyMetadata(false)); //DefaultStyleKeyProperty.OverrideMetadata(typeof(RadSplitButton), // new FrameworkPropertyMetadata(new ThemeResourceKey(typeof(Office_BlackTheme), typeof(RadSplitButton)))); DefaultStyleKeyProperty.OverrideMetadata(typeof(RadSplitButton), new FrameworkPropertyMetadata(typeof(RadSplitButton))); }
/// <summary> /// Initializes static members of the <see cref="TreeViewItemEx"/> class. /// </summary> static TreeViewItemEx() { DefaultStyleKeyProperty.OverrideMetadata(typeof(TreeViewItemEx), new FrameworkPropertyMetadata(typeof(TreeViewItemEx))); VirtualizingPanel.IsVirtualizingProperty.OverrideMetadata(typeof(TreeViewItemEx), new FrameworkPropertyMetadata(Boxed.BooleanFalse)); IsTabStopProperty.OverrideMetadata(typeof(TreeViewItemEx), new FrameworkPropertyMetadata(Boxed.BooleanFalse)); // Override BringIntoView behavior. EventManager.RegisterClassHandler(typeof(TreeViewItemEx), RequestBringIntoViewEvent, new RequestBringIntoViewEventHandler(OnRequestBringIntoView)); }
static TabControl() { DefaultStyleKeyProperty.OverrideMetadata(typeof(TabControl), new FrameworkPropertyMetadata(typeof(TabControl))); _dType = DependencyObjectType.FromSystemTypeInternal(typeof(TabControl)); IsTabStopProperty.OverrideMetadata(typeof(TabControl), new FrameworkPropertyMetadata(MS.Internal.KnownBoxes.BooleanBoxes.FalseBox)); KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata(typeof(TabControl), new FrameworkPropertyMetadata(KeyboardNavigationMode.Contained)); IsEnabledProperty.OverrideMetadata(typeof(TabControl), new UIPropertyMetadata(new PropertyChangedCallback(OnVisualStatePropertyChanged))); }
//-------------------------------------------------------------- #region Creation & Cleanup //-------------------------------------------------------------- /// <summary> /// Initializes static members of the <see cref="DockAnchorPane"/> class. /// </summary> static DockAnchorPane() { DefaultStyleKeyProperty.OverrideMetadata(typeof(DockAnchorPane), new FrameworkPropertyMetadata(typeof(DockAnchorPane))); HorizontalContentAlignmentProperty.OverrideMetadata(typeof(DockAnchorPane), new FrameworkPropertyMetadata(HorizontalAlignment.Stretch)); VerticalContentAlignmentProperty.OverrideMetadata(typeof(DockAnchorPane), new FrameworkPropertyMetadata(VerticalAlignment.Stretch)); // DockAnchorPane is not a tab stop, only the DockTabItems inside the DockPanes. IsTabStopProperty.OverrideMetadata(typeof(DockAnchorPane), new FrameworkPropertyMetadata(Boxed.BooleanFalse)); }
/// <summary> /// Static constructor /// </summary> static SeparatorTabItem() { var type = typeof(SeparatorTabItem); DefaultStyleKeyProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(type)); IsEnabledProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(BooleanBoxes.FalseBox, null, CoerceIsEnabledAndTabStop)); IsTabStopProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(BooleanBoxes.FalseBox, null, CoerceIsEnabledAndTabStop)); IsSelectedProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(BooleanBoxes.FalseBox, OnIsSelectedChanged)); }
static GroupSeparatorMenuItem() { Type type = typeof(GroupSeparatorMenuItem); DefaultStyleKeyProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(type)); StyleProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(null, new CoerceValueCallback(OnCoerceStyle))); IsEnabledProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(false, null, CoerceIsEnabledAndTabStop)); IsTabStopProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(false, null, CoerceIsEnabledAndTabStop)); }
/// <summary> /// Initializes static members of the <see cref="RibbonTabControl"/> class. /// </summary> static RibbonTabControl() { var type = typeof(RibbonTabControl); DefaultStyleKeyProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(typeof(RibbonTabControl))); IsTabStopProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(BooleanBoxes.FalseBox)); KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(KeyboardNavigationMode.Contained)); ContextMenuService.Attach(type); PopupService.Attach(type); }
static BlazorWebView() { // By default, prevent the BlazorWebView from receiving focus. Focus should typically be directed // to the underlying WebView2 control. FocusableProperty.OverrideMetadata(typeof(BlazorWebView), new FrameworkPropertyMetadata(false)); // Listen for changes to the IsTabStop property so we can manipulate how tab navigation affects // the BlazorWebView's subtree. IsTabStopProperty.OverrideMetadata(typeof(BlazorWebView), new FrameworkPropertyMetadata(OnIsTabStopPropertyChanged)); }
//------------------------------------------------------------------- // // Constructors // //------------------------------------------------------------------- #region Constructors static Expander() { DefaultStyleKeyProperty.OverrideMetadata(typeof(Expander), new FrameworkPropertyMetadata(typeof(Expander))); _dType = DependencyObjectType.FromSystemTypeInternal(typeof(Expander)); IsTabStopProperty.OverrideMetadata(typeof(Expander), new FrameworkPropertyMetadata(BooleanBoxes.FalseBox)); IsMouseOverPropertyKey.OverrideMetadata(typeof(Expander), new UIPropertyMetadata(new PropertyChangedCallback(OnVisualStatePropertyChanged))); IsEnabledProperty.OverrideMetadata(typeof(Expander), new UIPropertyMetadata(new PropertyChangedCallback(OnVisualStatePropertyChanged))); }
static SeparatorTabItem() { Type type = typeof(SeparatorTabItem); DefaultStyleKeyProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(type)); IsEnabledProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(false, null, CoerceIsEnabledAndTabStop)); IsTabStopProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(false, null, CoerceIsEnabledAndTabStop)); IsSelectedProperty.OverrideMetadata(type, new FrameworkPropertyMetadata(false, OnIsSelectedChanged)); StyleProperty.OverrideMetadata(typeof(SeparatorTabItem), new FrameworkPropertyMetadata(null, new CoerceValueCallback(OnCoerceStyle))); }
static MultiSelectTreeViewItem() { DefaultStyleKeyProperty.OverrideMetadata(typeof(MultiSelectTreeViewItem), new FrameworkPropertyMetadata(typeof(MultiSelectTreeViewItem))); IsTabStopProperty.OverrideMetadata(typeof(MultiSelectTreeViewItem), new FrameworkPropertyMetadata(false)); KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata(typeof(MultiSelectTreeViewItem), new FrameworkPropertyMetadata((object)KeyboardNavigationMode.Continue)); KeyboardNavigation.TabNavigationProperty.OverrideMetadata(typeof(MultiSelectTreeViewItem), new FrameworkPropertyMetadata((object)KeyboardNavigationMode.None)); EventManager.RegisterClassHandler(typeof(MultiSelectTreeViewItem), FrameworkElement.RequestBringIntoViewEvent, new RequestBringIntoViewEventHandler(OnRequestBringIntoView)); }
//------------------------------------------------------------------- // // Constructors // //------------------------------------------------------------------- #region Constructors static TabbedExpanderView() { DefaultStyleKeyProperty.OverrideMetadata(typeof(TabbedExpanderView), new FrameworkPropertyMetadata(typeof(TabbedExpanderView))); //_dType = DependencyObjectType.FromSystemTypeInternal(typeof(TabbedExpanderView)); IsTabStopProperty.OverrideMetadata(typeof(TabbedExpanderView), new FrameworkPropertyMetadata(false)); //IsMouseOverPropertyKey.OverrideMetadata(typeof(TabbedExpanderView), new UIPropertyMetadata(new PropertyChangedCallback(OnVisualStatePropertyChanged))); //IsEnabledProperty.OverrideMetadata(typeof(TabbedExpanderView), new UIPropertyMetadata(new PropertyChangedCallback(OnVisualStatePropertyChanged))); }
//------------------------------------------------------ // // Constructors // //------------------------------------------------------ #region Constructors /// <summary> /// Static constructor /// </summary> static Label() { EventManager.RegisterClassHandler(typeof(Label), AccessKeyManager.AccessKeyPressedEvent, new AccessKeyPressedEventHandler(OnAccessKeyPressed)); DefaultStyleKeyProperty.OverrideMetadata(typeof(Label), new FrameworkPropertyMetadata(typeof(Label))); _dType = DependencyObjectType.FromSystemTypeInternal(typeof(Label)); // prevent label from being a tab stop and focusable IsTabStopProperty.OverrideMetadata(typeof(Label), new FrameworkPropertyMetadata(MS.Internal.KnownBoxes.BooleanBoxes.FalseBox)); FocusableProperty.OverrideMetadata(typeof(Label), new FrameworkPropertyMetadata(MS.Internal.KnownBoxes.BooleanBoxes.FalseBox)); }
static InlineWindowTitleBarButton() { // Override default properties IsTabStopProperty.OverrideMetadata( typeof(InlineWindowTitleBarButton), new FrameworkPropertyMetadata(false)); FocusableProperty.OverrideMetadata( typeof(InlineWindowTitleBarButton), new FrameworkPropertyMetadata(false)); }
static ArtPathPatternBox() { //This OverrideMetadata call tells the system that this element wants to provide a style that is different than its base class. //This style is defined in themes\generic.xaml DefaultStyleKeyProperty.OverrideMetadata(typeof(ArtPathPatternBox), new FrameworkPropertyMetadata(typeof(ArtPathPatternBox))); //The control itself shouldn't be a tab stop (it's inner controls are) IsTabStopProperty.OverrideMetadata(typeof(ArtPathPatternBox), new FrameworkPropertyMetadata(false)); KeyboardNavigation.TabNavigationProperty.OverrideMetadata(typeof(ArtPathPatternBox), new FrameworkPropertyMetadata(KeyboardNavigationMode.Local)); KeyboardNavigation.ControlTabNavigationProperty.OverrideMetadata(typeof(ArtPathPatternBox), new FrameworkPropertyMetadata(KeyboardNavigationMode.None)); KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata(typeof(ArtPathPatternBox), new FrameworkPropertyMetadata(KeyboardNavigationMode.None)); }
//------------------------------------------------------------------- // // Constructors // //------------------------------------------------------------------- #region Constructors static StatusBar() { DefaultStyleKeyProperty.OverrideMetadata(typeof(StatusBar), new FrameworkPropertyMetadata(typeof(StatusBar))); _dType = DependencyObjectType.FromSystemTypeInternal(typeof(StatusBar)); IsTabStopProperty.OverrideMetadata(typeof(StatusBar), new FrameworkPropertyMetadata(BooleanBoxes.FalseBox)); ItemsPanelTemplate template = new ItemsPanelTemplate(new FrameworkElementFactory(typeof(DockPanel))); template.Seal(); ItemsPanelProperty.OverrideMetadata(typeof(StatusBar), new FrameworkPropertyMetadata(template)); }
/// <summary> /// Initializes static members of the <see cref="DockTabPane"/> class. /// </summary> static DockTabPane() { DefaultStyleKeyProperty.OverrideMetadata(typeof(DockTabPane), new FrameworkPropertyMetadata(typeof(DockTabPane))); // DockTabPane is not a tab stop, only the DockTabItems IsTabStopProperty.OverrideMetadata(typeof(DockTabPane), new FrameworkPropertyMetadata(Boxed.BooleanFalse)); // We handle the access key events to make sure that it behaves properly. EventManager.RegisterClassHandler(typeof(DockTabPane), AccessKeyManager.AccessKeyPressedEvent, new AccessKeyPressedEventHandler(OnAccessKeyPressed)); // Keyboard navigation with arrow keys cycles through DockTabItems KeyboardNavigation.DirectionalNavigationProperty.OverrideMetadata(typeof(DockTabPane), new FrameworkPropertyMetadata(KeyboardNavigationMode.Contained)); }