private void mouseHook_LeftButtonDown(WinAPI.MSLLHOOKSTRUCT mouseStruct)
        {
            if (wndPinballBrowser == IntPtr.Zero)
            {
                wndPinballBrowser    = WinAPI.WindowFromPoint(mouseStruct.pt);
                btnStartStop.Enabled = true;

                HookEnabled = false;
                mouseHook.Uninstall();
            }
        }
Beispiel #2
0
 private void notifyIcon1_MouseDoubleClick(object sender, MouseEventArgs e)
 {
     mouseHook.Uninstall();
     if (radioButton5.Checked)
     {
         timer1.Stop();
     }
     if (radioButton4.Checked)
     {
         timer2.Stop();
     }
     this.Visible = true;
     this.Activate();
 }
 private void UnistallMouseAndKeyboard()
 {
     keyboardHook.KeyPress -= new RamGecTools.KeyboardHook.myKeyboardHookCallback(keyboardHook_KeyPress);
     mouseHook.MouseEvent  -= new RamGecTools.MouseHook.myMouseHookCallback(mouseHook_MouseEvent);
     keyboardHook.Uninstall();
     mouseHook.Uninstall();
     this.MouseWheel += MouseWheelEventHandler;
 }
Beispiel #4
0
        private void mouseHookBox_CheckedChanged(object sender, EventArgs e)
        {
            if (mouseHookBox.Checked)
            {
                mouseGroup.Enabled = true;

                // register events
                mouseHook.MouseMove        += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_MouseMove);
                mouseHook.LeftButtonDown   += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_LeftButtonDown);
                mouseHook.LeftButtonUp     += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_LeftButtonUp);
                mouseHook.RightButtonDown  += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_RightButtonDown);
                mouseHook.RightButtonUp    += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_RightButtonUp);
                mouseHook.MiddleButtonDown += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_MiddleButtonDown);
                mouseHook.MiddleButtonUp   += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_MiddleButtonUp);
                mouseHook.MouseWheel       += new RamGecTools.MouseHook.MouseHookCallback(mouseHook_MouseWheel);

                mouseHook.Install();
            }
            else
            {
                mouseGroup.Enabled = false;
                mouseHook.Uninstall();
            }
        }
Beispiel #5
0
 private void checkBoxSincr_CheckedChanged(object sender, EventArgs e)
 {
     if (checkBoxSincr.Checked)
     {
         Senzor = null;
         CapturaSenzor(); //Ar trebui sa captureze Senzorul
         if (Senzor != null)
         {
             //checkBoxSincr.Checked = true;
             MH.Install();
         }
         else
         {
             checkBoxSincr.Checked = false;
         }
     }
     else
     {
         MH.Uninstall();
     }
 }