本文整理匯總了VB.NET中System.Windows.Forms.FontDialog.HookProc方法的典型用法代碼示例。如果您正苦於以下問題:VB.NET FontDialog.HookProc方法的具體用法?VB.NET FontDialog.HookProc怎麽用?VB.NET FontDialog.HookProc使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類System.Windows.Forms.FontDialog
的用法示例。
在下文中一共展示了FontDialog.HookProc方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的VB.NET代碼示例。
示例1: HookProc
' Defines the constants for Windows messages.
Const WM_SETFOCUS = &H7
Const WM_INITDIALOG = &H110
Const WM_LBUTTONDOWN = &H201
Const WM_RBUTTONDOWN = &H204
Const WM_MOVE = &H3
<System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.Demand, Name:="FullTrust")> _
Protected Overrides Function HookProc(ByVal hWnd As IntPtr, ByVal msg As Integer, ByVal wParam As IntPtr, ByVal lParam As IntPtr) As IntPtr
' Evaluates the message parameter to determine the user action.
Select Case msg
Case WM_INITDIALOG
System.Diagnostics.Trace.Write("The WM_INITDIALOG message was received.")
Case WM_SETFOCUS
System.Diagnostics.Trace.Write("The WM_SETFOCUS message was received.")
Case WM_LBUTTONDOWN
System.Diagnostics.Trace.Write("The WM_LBUTTONDOWN message was received.")
Case WM_RBUTTONDOWN
System.Diagnostics.Trace.Write("The WM_RBUTTONDOWN message was received.")
Case WM_MOVE
System.Diagnostics.Trace.Write("The WM_MOVE message was received.")
End Select
' Always call the base class hook procedure.
Return MyBase.HookProc(hWnd, msg, wParam, lParam)
End Function