我以前使用AutoHotKey脚本来实现Spotify快捷方式(内置快捷方式有限,只有在应用程序处于焦点时才有效,我通常会在工作中将其保留在后台)。
无论如何,它已经更新了一百万次没有问题..但我下载了最新的spotify更新,它不再有效。知道为什么吗?
这是剧本。
#z::Run www.autohotkey.com
SetTitleMatchMode 2
; "CTRL + LEFT" for previous
^Left::
{
DetectHiddenWindows, On
ControlSend, ahk_parent, ^{Left}, ahk_class SpotifyMainWindow
DetectHiddenWindows, Off
return
}
; "CTRL + RIGHT" for next
^Right::
{
DetectHiddenWindows, On
ControlSend, ahk_parent, ^{Right}, ahk_class SpotifyMainWindow
DetectHiddenWindows, Off
return
}
; "CTRL + UP" for pause
^UP::
{
DetectHiddenWindows, On
ControlSend, ahk_parent, {space}, ahk_class SpotifyMainWindow
DetectHiddenWindows, Off
return
}
; "CTRL + DOWN" for info
^Down::
{
DetectHiddenWindows, On
SetTitleMatchMode 2
WinGetTitle, now_playing, ahk_class SpotifyMainWindow
StringTrimLeft, playing, now_playing, 10
DetectHiddenWindows, Off
clipboard = %playing%`r`n
return
}
; "CTRL + PAGE UP" for volume up
^PgUP::
{
DetectHiddenWindows, On
ControlSend, ahk_parent, ^{Up}, ahk_class SpotifyMainWindow
DetectHiddenWindows, Off
return
}
; "CTRL + PAGE DOWN" for volume down
^PgDn::
{
DetectHiddenWindows, On
ControlSend, ahk_parent, ^{Down}, ahk_class SpotifyMainWindow
DetectHiddenWindows, Off
return
}
; "CTRL + END" for mute
^End::
{
DetectHiddenWindows, On
ControlSend, ahk_parent, ^+{Down}, ahk_class SpotifyMainWindow
DetectHiddenWindows, Off
return
}
答案 0 :(得分:1)
请参阅此问题:Hotkey for next song in Spotify - 包括Spotify开发人员的声明,以及将在即将发布的版本中修复的声明,以及目前的解决方法:
^Left::Media_Prev