Skip to content

Instantly share code, notes, and snippets.

@davebrny
Last active October 3, 2019 14:48
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davebrny/63d8120c9f31c0505cfed1cfa9a6e68e to your computer and use it in GitHub Desktop.
Save davebrny/63d8120c9f31c0505cfed1cfa9a6e68e to your computer and use it in GitHub Desktop.
(autohotkey) - default items for the tray menu
; default items for the tray menu
tray_open:
listLines
return
tray_help:
splitpath, a_ahkPath, , ahk_dir
run, % ahk_dir "\AutoHotkey.chm"
return
tray_window_spy:
splitpath, a_ahkPath, , ahk_dir
run, % ahk_dir "\AU3_Spy.exe"
return
tray_reload:
reload
sleep 1000
msgBox, 4, , The script could not be reloaded and will need to be manually restarted. Would you like Exit?
ifMsgBox, yes, exitApp
return
tray_edit:
run, edit %a_scriptFullPath% ; open in the default note editor
return
tray_suspend:
suspend toggle
if (a_isSuspended = 1)
menu, tray, check , Suspend Hotkeys
else menu, tray, unCheck, Suspend Hotkeys
return
tray_pause:
if (a_isPaused = 1)
{
pause off
menu, tray, unCheck, Pause Script
}
else
{
menu, tray, check, Pause Script
pause on
}
return
tray_exit:
exitApp
/*
.ahk
----
menu, tray, noStandard
menu, tray, add, Open , tray_open
menu, tray, add, Help , tray_help
menu, tray, add,
menu, tray, add, Window Spy , tray_window_spy
menu, tray, add, Reload This Script , tray_reload
menu, tray, add, Edit This Script , tray_edit
menu, tray, add,
menu, tray, add, Suspend Hotkeys , tray_suspend
menu, tray, add, Pause Script , tray_pause
menu, tray, add, Exit , tray_exit
.exe
----
menu, tray, noStandard
menu, tray, add, Suspend Hotkeys , tray_suspend
menu, tray, add, Pause Script , tray_pause
menu, tray, add, Exit , tray_exit
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment