 	MouseMove, x, y, 0, R
 }
 
+; Handle the keydown for each of the mouse movement directions
+; TODO: Maybe a way to simplify this?
 MouseUp:
 	Move( 0, -1 )
 	return


return

SetKeys( mod ) {
	
	; Left hand


#SingleInstance force

; Use either the embedded icon in a compiled .exe,
; or a separate .ico file when running the .ahk script.
iconPath := RegExReplace( A_ScriptFullPath, "i).ahk$", ".ico" )

; Set up the tray icon and menu
Menu, Tray, Icon, %iconPath%
Menu, Tray, Tip, JKLmouse
Menu, Tray, Add
Menu, Tray, Add, About JKLmouse, MenuAbout

; Display tray balloon
; TODO: more useful content?
; TODO: display this only during an install
TrayTip JKLmouse, The Automatic Keyboard Mouse

; Remove forced delay between triggered mouse events.
; TODO: experiment with this when accelerated
SetMouseDelay, -1

; Hotkey repeat count for acceleration
repeat := 0

; Each of these modifier keys enables the same set of JKLmouse hotkeys
SetKeys( "CapsLock" )
SetKeys( "~LButton" )
SetKeys( "~RButton" )
