Questions are always welcome!
Code: Select all
holdin := false
!LButton:: {
global holdin
if (holdin) {
send("{LButton Up}")
holdin := false
} else {
send("{LButton Down}")
holdin := true
}
}
~LButton::global holdin := false
Code: Select all
!LButton:: {
global holdin
if (!isSet(holdin))
holdin:=false
if (holdin) {
send("{LButton Up}")
holdin := false
} else {
send("{LButton Down}")
holdin := true
}
}
~LButton::global holdin := false
Code: Select all
!LButton:: {
global holdin
if (holdin??false) {
send("{LButton Up}")
holdin := false
} else {
send("{LButton Down}")
holdin := true
}
}
~LButton::global holdin := false
Code: Select all
!LButton:: {
global holdin
if (holdin??false)
send("{LButton Up}")
else
send("{LButton Down}")
holdin := !holdin
}
~LButton::global holdin := false
Code: Select all
!LButton:: {
global holdin
send("{LButton " ((holdin??false)?"Up":"Down") "}")
holdin := !holdin
}
~LButton::global holdin := false
Code: Select all
!LButton:: {
global holdin := holdin??false
send(format("{1}"
,"{LButton " (holdin?"Up":"Down") "}"
,holdin := !holdin))
}
~LButton::global holdin := false
Code: Select all
!LButton:: {
global holdin
send (sendkey := "{LButton " ((holdin??false)?"Up":"Down") "}"
,holdin := !holdin
,sendkey)
}
~LButton::global holdin := false
Code: Select all
!LButton::send("{LButton " (HoldIn.state?"Up":"Down") "}"), HoldIn.state := !HoldIn.state
~LButton::HoldIn.state := false
class HoldIn {
static state := false
}
Code: Select all
!LButton::HoldIn.altLButton()
~LButton::HoldIn.t_LButton()
class HoldIn {
static _state := false
static altLButton() {
send("{LButton " (this._state?"Up":"Down") "}"), this._state := !this._state
}
static t_LButton() {
this._state := false
}
}
Code: Select all
!LButton::HoldIn.altLButton()
~LButton::HoldIn.t_LButton()
class HoldIn {
static _state := false
static altLButton() => send((sendkey := "{LButton " (this._state?"Up":"Down") "}", this._state := !this._state, sendkey))
static t_LButton() => this._state := false
}
Code: Select all
!LButton::
~LButton:: {
HoldIn.onHotkey(A_ThisHotkey)
}
class HoldIn {
static _state := false
static onHotkey(thisKey) {
switch (thisKey)
{
case "!LButton": send("{LButton " (this._state?"Up":"Down") "}"), this._state := !this._state
case "~LButton": this._state := false
}
}
}