Beispiel #1
0
 public static GlobalHook Create(HookTypes type)
 {
     GlobalHook hook = new GlobalHook {
         mHookType = type
     };
     hook.Install();
     EventLog.WriteLine("Created global hook of type: {0}", new object[] { type });
     return hook;
 }
Beispiel #2
0
 private static void IgnoreGlobalHook(GlobalHook sender, HookEventArgs e)
 {
     EventLog.WriteLine("Ignored hook: {0}, WP: {1}, LP: {2}", new object[] { e.Code, e.WParam, e.LParam });
     e.Continue = false;
 }