diff options
Diffstat (limited to 'tt.doubleclick.ahk')
-rw-r--r-- | tt.doubleclick.ahk | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/tt.doubleclick.ahk b/tt.doubleclick.ahk index 58d83f4..bb84977 100644 --- a/tt.doubleclick.ahk +++ b/tt.doubleclick.ahk @@ -1,9 +1,7 @@ ;; DoubleClick function ;; ============================================================================ -;; DoubleClick returns true if a double click has been performed. The first -;; click in the double click is allowed to pass through, but the second click -;; is prevented. +;; DoubleClick returns true if a double click has been performed. ;; To use the function, call it whenever the user clicks. The function returns ;; true if two calls in a row meet the requirements for a double click. @@ -11,9 +9,7 @@ ;; Function definition -> library ;; ---------------------------------------------------------------------------- -;; The 'alternate' argument, if set to true, signifies a right click: - -DoubleClick(alternate := false) +DoubleClick() { ;; A bunch of global variables are needed to determine whether a double click @@ -55,10 +51,6 @@ DoubleClickClicked := false if (not DoubleClickClicked) { - if (alternate) - SendInput, {Click, right} - else - SendInput, {Click} DoubleClickPriorX := x DoubleClickPriorY := y DoubleClickLast := A_TickCount @@ -75,10 +67,6 @@ DoubleClickClicked := false || abs(x - DoubleClickPriorX) > SM_CXDOUBLECLK || abs(y - DoubleClickPriorY) > SM_CYDOUBLECLK) { - if (alternate) - SendInput, {Click, right} - else - SendInput, {Click} DoubleClickPriorX := x DoubleClickPriorY := y DoubleClickLast := A_TickCount |