예제 #1
0
 public static bool Disable()
 {
     if (bool_0)
     {
         try
         {
             Hooks.UnhookWindowsHookEx(intptr_0);
             bool_0 = false;
             return(true);
         }
         catch
         {
             bool_0 = true;
             return(false);
         }
     }
     return(false);
 }
예제 #2
0
 /// <summary>
 /// Disable keyboard hooking.
 /// </summary>
 /// <returns>True if disabled correctly.</returns>
 public static bool Disable()
 {
     if (Enabled == true)
     {
         try
         {
             Hooks.UnhookWindowsHookEx(hHook);
             Enabled = false;
             return(true);
         }
         catch
         {
             Enabled = true;
             return(false);
         }
     }
     else
     {
         return(false);
     }
 }