C# 클래스 ControlzEx.KeyboardNavigationEx

Helper class for a common focusing problem. The focus itself isn't the problem. If we use the common focusing methods the control get the focus but it doesn't get the focus visual style. The KeyboardNavigation class handles the visual style only if the control get the focus from a keyboard device or if the SystemParameters.KeyboardCues is true.
파일 보기 프로젝트 열기: ControlzEx/ControlzEx 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
AlwaysShowFocusVisualProperty System.Windows.DependencyProperty

Private Properties

프로퍼티 타입 설명
AlwaysShowFocusVisualPropertyChangedCallback void
FrameworkElementGotFocus void
GetAlwaysShowFocusVisual bool
KeyboardNavigationEx System
ShowFocusVisualInternal void

공개 메소드들

메소드 설명
Focus ( UIElement element ) : void

Focuses the specified element and shows the focus visual style.

SetAlwaysShowFocusVisual ( UIElement element, bool value ) : void

Sets a the value which indicates if the UI element always show the focus visual style.

비공개 메소드들

메소드 설명
AlwaysShowFocusVisualPropertyChangedCallback ( DependencyObject dependencyObject, System.Windows.DependencyPropertyChangedEventArgs args ) : void
FrameworkElementGotFocus ( object sender, RoutedEventArgs e ) : void
GetAlwaysShowFocusVisual ( UIElement element ) : bool
KeyboardNavigationEx ( ) : System
ShowFocusVisualInternal ( ) : void

Shows the focus visual of the current focused UI element. Works only together with AlwaysShowFocusVisual property.

메소드 상세

Focus() 공개 정적인 메소드

Focuses the specified element and shows the focus visual style.
public static Focus ( UIElement element ) : void
element System.Windows.UIElement The element which will be focused.
리턴 void

SetAlwaysShowFocusVisual() 공개 정적인 메소드

Sets a the value which indicates if the UI element always show the focus visual style.
public static SetAlwaysShowFocusVisual ( UIElement element, bool value ) : void
element System.Windows.UIElement
value bool
리턴 void

프로퍼티 상세

AlwaysShowFocusVisualProperty 공개적으로 정적으로 프로퍼티

Attached DependencyProperty for setting AlwaysShowFocusVisual for a UI element.
public static DependencyProperty,System.Windows AlwaysShowFocusVisualProperty
리턴 System.Windows.DependencyProperty