UICuesEventArgs 类
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
提供事件的数据 ChangeUICues 。
public ref class UICuesEventArgs : EventArgs
public class UICuesEventArgs : EventArgs
type UICuesEventArgs = class
inherit EventArgs
Public Class UICuesEventArgs
Inherits EventArgs
- 继承
示例
下面的代码示例演示了此类型的用法。 在此示例中,事件处理程序报告事件的发生情况 ChangeUICues 。 此报告可帮助你了解事件发生的时间,并可以帮助你进行调试。 若要报告多个事件或频繁发生的事件,请考虑替换ShowConsole.WriteLine或将消息追加到多行TextBox。
若要运行示例代码,请将其粘贴到包含继承自 Control的类型实例的项目(如 Button 或 ComboBox)。 然后为实例 Control1 命名,并确保事件处理程序与 ChangeUICues 该事件相关联。
private void Control1_ChangeUICues(Object sender, UICuesEventArgs e) {
System.Text.StringBuilder messageBoxCS = new System.Text.StringBuilder();
messageBoxCS.AppendFormat("{0} = {1}", "ShowFocus", e.ShowFocus );
messageBoxCS.AppendLine();
messageBoxCS.AppendFormat("{0} = {1}", "ShowKeyboard", e.ShowKeyboard );
messageBoxCS.AppendLine();
messageBoxCS.AppendFormat("{0} = {1}", "ChangeFocus", e.ChangeFocus );
messageBoxCS.AppendLine();
messageBoxCS.AppendFormat("{0} = {1}", "ChangeKeyboard", e.ChangeKeyboard );
messageBoxCS.AppendLine();
messageBoxCS.AppendFormat("{0} = {1}", "Changed", e.Changed );
messageBoxCS.AppendLine();
MessageBox.Show(messageBoxCS.ToString(), "ChangeUICues Event" );
}
Private Sub Control1_ChangeUICues(sender as Object, e as UICuesEventArgs) _
Handles Control1.ChangeUICues
Dim messageBoxVB as New System.Text.StringBuilder()
messageBoxVB.AppendFormat("{0} = {1}", "ShowFocus", e.ShowFocus)
messageBoxVB.AppendLine()
messageBoxVB.AppendFormat("{0} = {1}", "ShowKeyboard", e.ShowKeyboard)
messageBoxVB.AppendLine()
messageBoxVB.AppendFormat("{0} = {1}", "ChangeFocus", e.ChangeFocus)
messageBoxVB.AppendLine()
messageBoxVB.AppendFormat("{0} = {1}", "ChangeKeyboard", e.ChangeKeyboard)
messageBoxVB.AppendLine()
messageBoxVB.AppendFormat("{0} = {1}", "Changed", e.Changed)
messageBoxVB.AppendLine()
MessageBox.Show(messageBoxVB.ToString(),"ChangeUICues Event")
End Sub
注解
指定 UICuesEventArgs 哪些用户界面功能已更改及其新值。
用户界面 ChangeUICues 通过显示或隐藏焦点指示器或键盘提示来更改时发生该事件。这通常是当用户按下 TAB、ALT 或 F10 键时。
有关事件模型的信息,请参阅 处理和引发事件。
构造函数
| 名称 | 说明 |
|---|---|
| UICuesEventArgs(UICues) |
用指定的UICuesEventArgs值初始化类的新实例UICues。 |
属性
| 名称 | 说明 |
|---|---|
| Changed |
获取值的按位组合 UICues 。 |
| ChangeFocus |
获取一个值,该值指示焦点提示的状态是否已更改。 |
| ChangeKeyboard |
获取一个值,该值指示键盘提示的状态是否已更改。 |
| ShowFocus |
获取一个值,该值指示是否在更改后显示焦点矩形。 |
| ShowKeyboard |
获取一个值,该值指示更改后键盘提示是否带下划线。 |
方法
| 名称 | 说明 |
|---|---|
| Equals(Object) |
确定指定的对象是否等于当前对象。 (继承自 Object) |
| GetHashCode() |
用作默认哈希函数。 (继承自 Object) |
| GetType() |
获取当前实例的 Type。 (继承自 Object) |
| MemberwiseClone() |
创建当前 Object的浅表副本。 (继承自 Object) |
| ToString() |
返回一个表示当前对象的字符串。 (继承自 Object) |