-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.ahk
125 lines (112 loc) · 2.26 KB
/
main.ahk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
SomeThingDone := 0
PauseFlag := 0
Flag_RButtonDown := 0
tooltip, 开/关全局右键: <Ctrl-Win-Alt-F12>`n关全局右键: 三次单击右键后在圆圈中心单击中键
SetTimer, _RemoveTooltip, -2200
#Include %A_ScriptDir%\globalRButton\globalRButton.ahk
#Include %A_ScriptDir%\globalRButton\_markFlag.ahk
#Include %A_ScriptDir%\funcs\moveWindow.ahk
#Include %A_ScriptDir%\funcs\resizeWindow.ahk
#Include %A_ScriptDir%\keyboard\keyboard.ahk
; ++++++++++++++++++++++++++++++++++++++
; GlobalRButton
; ++++++++++++++++++++++++++++++++++++++
; 全局右键
#if !IsRemoteDesktop and !PauseFlag
RButton::
Send, {LWin Up}
Send, {Ctrl Up}
Send, {Alt Up}
Send, {Sifht Up}
GoSub, GlobalRButton
Return
; 全局右键 - 结束
#if !IsRemoteDesktop and !PauseFlag
RButton Up::
GoSub, GlobalRButtonEnd
GoSub, _Mark_RightUp
Return
; 全局右键 - 标记左键
#if !IsRemoteDesktop
~LButton::
if (PauseFlag) {
Return
}
GoSub, _Mark_LeftDown
Return
#if !IsRemoteDesktop
~LButton Up::
if (PauseFlag) {
Return
}
GoSub, _Mark_LeftUp
Return
; 全局右键 - 标记中键
#if !IsRemoteDesktop
~MButton::
if (PauseFlag) {
Return
}
GoSub, _Mark_MButtonDown
Return
#if !IsRemoteDesktop
~MButton Up::
if (PauseFlag) {
Return
}
GoSub, _Mark_MButtonUp
Return
#if !IsRemoteDesktop
~RButton & MButton Up::
if (PauseFlag) {
Return
}
GoSub, _Mark_MButtonUp
Return
; 全局右键 - 标记滚轮
#if !IsRemoteDesktop and !PauseFlag
WheelUp::
GoSub, _Mark_WheelUp
Return
#if !IsRemoteDesktop and !PauseFlag
WheelDown::
GoSub, _Mark_WheelDown
Return
; ++++++++++++++++++++++++++++++++++++++
; GlobalRButton
; ++++++++++++++++++++++++++++++++++++++
#if !IsRemoteDesktop
~RButton & LButton::
if (PauseFlag) {
Return
}
GoSub, _Mark_LeftDown
if (RButtonPressCnt == 1) {
GoSub, MoveWindow
}
Return
#if !IsRemoteDesktop
~RButton & MButton::
if (PauseFlag) {
GoSub, RestoreGlobalMouse
Return
}
GoSub, _Mark_MButtonDown
if (RButtonPressCnt == 1) {
GoSub, ResizeWindow
}
Return
#if !IsRemoteDesktop
~^#!f12::
PauseFlag := !PauseFlag
if (PauseFlag == 1) {
PauseGlobalMouse(0)
} else {
GoSub, RestoreGlobalMouse
}
SetTimer, _RemoveTooltip, -2200
Return
~F11::
ret := GetIni_MainMouseButton()
tooltip, %ret%
Return