-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathmeta_nav.ahk
More file actions
32 lines (28 loc) · 909 Bytes
/
meta_nav.ahk
File metadata and controls
32 lines (28 loc) · 909 Bytes
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
#Requires AutoHotkey v2.0
#SingleInstance Force
~LAlt::Send("{Blind}{vkE8}")
FocusOrRun(exePath, runCommand := "") {
static prevWindow := 0
target := "ahk_exe " exePath
if WinExist(target) {
if WinActive(target) {
if WinExist("ahk_id " prevWindow)
WinActivate("ahk_id " prevWindow)
} else {
prevWindow := WinExist("A")
WinActivate(target)
}
} else {
if (runCommand = "")
Run exePath
else
Run runCommand
}
}
#^!+n::FocusOrRun("neovide.exe", "neovide.exe --wsl --frame none")
#^!+i::FocusOrRun("opera.exe")
#^!+c::FocusOrRun("chrome.exe")
#^!+s::FocusOrRun("Discord.exe", "Discord.exe --processStart Discord.exe")
#^!+m::FocusOrRun("Spotify.exe")
#^!+g::FocusOrRun("steam.exe", "C:\Program Files (x86)\Steam\steam.exe")
#^!+f::FocusOrRun("WindowsTerminal.exe", "wt.exe")