Тема: AHK: Откуда берется Ctrl???
Добрый день!
Необходимо на горячие клавиши Shift+Alt+ЛКМ назначить нажатие СКМ+ПКМ.
Смог написать вот такой код:
!+LButton::
SendInput {MButton down}{RButton down}
Loop
{
Sleep, 10
GetKeyState, state, LButton, P
if state = U
break
}
SendInput {MButton up}{RButton up}
return
Скрипт вроде работает, но если записать на MacroRecorder или другой рекордер макросов выдаст:
Keyboard : ShiftLeft : KeyDown
Keyboard : AltLeft : KeyDown
Mouse : 193 : 306 : LeftButtonDown : 0 : 0 : 0
Keyboard : ControlLeft : KeyDown
Keyboard : ControlLeft : KeyUp
Keyboard : ControlLeft : KeyDown
Keyboard : ControlLeft : KeyUp
Keyboard : AltLeft : KeyUp
Keyboard : ShiftLeft : KeyUp
Mouse : 193 : 306 : MiddleButtonDown : 0 : 0 : 0
Mouse : 193 : 306 : RightButtonDown : 0 : 0 : 0
Keyboard : ControlLeft : KeyDown
Keyboard : AltLeft : KeyDown
Keyboard : ControlLeft : KeyUp
Keyboard : ShiftLeft : KeyDown
Keyboard : ControlLeft : KeyDown
Keyboard : ControlLeft : KeyUp
Keyboard : AltLeft : KeyUp
Keyboard : ShiftLeft : KeyUp
Mouse : 236 : 336 : MiddleButtonUp : 0 : 0 : 0
Mouse : 236 : 336 : RightButtonUp : 0 : 0 : 0
Keyboard : AltLeft : KeyDown
Keyboard : AltLeft : KeyDown
Keyboard : AltLeft : KeyUp
Keyboard : ShiftLeft : KeyUp
Откуда то появляется Ctrl который делает невозможным использование Alt+Shift в других комбинациях в этой программе. Экспериментально проверил любое Alt+ЛКМ выдаёт многократное Ctrl в потоке .((( В чём ошибка?
Заранее благодарю!