Exemplo n.º 1
0
 public CbtHook(IWin32Window owner)
 {
     _owner       = owner;
     _cbtHookProc = new NativeMethods.CbtHookProcDelegate(CbtHookProc);
     _hook        = NativeMethods.SetWindowsHookEx(NativeMethods.WH_CBT, _cbtHookProc, IntPtr.Zero, NativeMethods.GetCurrentThreadId());
     Debug.WriteLine(string.Format(CultureInfo.InvariantCulture, "I: Created CBT hook (ID={0}).    {{Medo.MessageBox}}", _hook.ToString()));
 }
Exemplo n.º 2
0
 public CbtHook(IWin32Window owner)
 {
     this._owner       = owner;
     this._cbtHookProc = new NativeMethods.CbtHookProcDelegate(CbtHookProc);
     this._hook        = NativeMethods.SetWindowsHookEx(NativeMethods.WH_CBT, this._cbtHookProc, System.IntPtr.Zero, NativeMethods.GetCurrentThreadId());
     System.Diagnostics.Debug.WriteLine(string.Format(System.Globalization.CultureInfo.InvariantCulture, "I: Created CBT hook (ID={0}).    {{Medo.MessageBox}}", this._hook.ToString()));
 }
Exemplo n.º 3
0
 public CbtHook(IWin32Window owner)
 {
     this._owner = owner;
     this._cbtHookProc = new NativeMethods.CbtHookProcDelegate(CbtHookProc);
     this._hook = NativeMethods.SetWindowsHookEx(NativeMethods.WH_CBT, this._cbtHookProc, System.IntPtr.Zero, NativeMethods.GetCurrentThreadId());
     System.Diagnostics.Debug.WriteLine(string.Format(System.Globalization.CultureInfo.InvariantCulture, "I: Created CBT hook (ID={0}).    {{Medo.MessageBox}}", this._hook.ToString()));
 }