ContextNodeDeletingEventArgs 类
为 ContextNodeDeleting 事件提供数据。
命名空间: Microsoft.Ink
程序集: Microsoft.Ink.Analysis(在 Microsoft.Ink.Analysis.dll 中)
语法
声明
Public Class ContextNodeDeletingEventArgs _
Inherits EventArgs
用法
Dim instance As ContextNodeDeletingEventArgs
public class ContextNodeDeletingEventArgs : EventArgs
public ref class ContextNodeDeletingEventArgs : public EventArgs
public class ContextNodeDeletingEventArgs extends EventArgs
public class ContextNodeDeletingEventArgs extends EventArgs
备注
有关处理事件的更多信息,请参见 Consuming Events(使用事件)。
示例
下面的示例定义 RemoveContextNode 方法,用以处理 ContextNodeDeleting 事件。事件信息将传递给文档模型对象 theDocumentModel。
此示例不提供文档模型的定义,也不演示文档模型如何处理传入的信息。
'/ <summary>
'/ Handles the InkAnalyzer.ContextNodeDeleting event.
'/ </summary>
'/ <param name="sender">The source of the event.</param>
'/ <param name="e">The event data.</param>
Private Sub RemoveContextNode( _
ByVal sender As Object, _
ByVal e As Microsoft.Ink.ContextNodeDeletingEventArgs)
' Do not remove unclassified ink nodes from the document model.
If Microsoft.Ink.ContextNodeType.UnclassifiedInk _
<> e.NodeToBeDeleted.Type Then
Me.theDocumentModel.RemoveNode(e.NodeToBeDeleted)
End If
End Sub 'RemoveContextNode
/// <summary>
/// Handles the InkAnalyzer.ContextNodeDeleting event.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The event data.</param>
private void RemoveContextNode(
object sender, Microsoft.Ink.ContextNodeDeletingEventArgs e)
{
// Do not remove unclassified ink nodes from the document model.
if (Microsoft.Ink.ContextNodeType.UnclassifiedInk
!= e.NodeToBeDeleted.Type)
{
this.theDocumentModel.RemoveNode(e.NodeToBeDeleted);
}
}
继承层次结构
System.Object
System.EventArgs
Microsoft.Ink.ContextNodeDeletingEventArgs
线程安全
此类型的任何公共 static(在 Visual Basic 中为 Shared) 成员都是线程安全的。但不保证所有实例成员都是线程安全的。
平台
Windows Vista
.NET Framework 和 .NET Compact Framework 并不是对每个平台的所有版本都提供支持。有关支持的版本的列表,请参见.NET Framework 系统要求。
版本信息
.NET Framework
受以下版本支持:3.0