1

Winamp 有一个简洁的功能。全局键。这样,即使 Winamp GUI 没有焦点,我也可以更改正在播放的歌曲。

我正在寻找与 Firefox 或 Chrome 类似的解决方案

我使用 Eclipse 编写 PHP 代码。它自动 SSH 并保存到另一台机器(测试) 我可以使用XRefresh 之类的东西和映射的虚拟驱动器,但我无法在测试机器上安装 Samba。

现在我必须:

CTRL+ S(保存并自动更新)
ALT+ TAB(切换到 Firefox GUI)
F5(刷新当前 Firefox 页面)
ALT+ TAB(返回 Eclipse)

我正在寻找类似的东西:

CTRL+ S(保存和自动更新)
CTRL+ X(刷新 Firefox - 同时保持专注于 Eclipse)

我查看了 Firefox 插件,但没有发现任何我需要的东西。铬也没有。XRefresh 将是一个完美的解决方案,但如前所述,无法通过 SSH/Samba 进入测试机器。

4

3 回答 3

4

自动热键

让我为 awesome.ahc 文件添加我的结果:

^s::
SetTitleMatchMode, 2
IfWinExist, Mozilla Firefox
{
   WinActivate, Mozilla Firefox
   ControlSend, ahk_parent, {F5}, Mozilla Firefox
}
Return

这将切换到 Firefox 并刷新当前活动的选项卡。

于 2009-09-25T12:05:18.543 回答
1

使用弗兰基的回答,我开发了一些更高级的东西。我的编辑器是 Aptana,但您可以轻松地将其更改为其他任何内容:

$^s::                                       ; only capture actual keystrokes
SetTitleMatchMode, 2                        ; match anywhere in the title
IfWinActive, Aptana Studio 3                ; find aptana
{
    Send ^s                                 ; send save command
    IfWinExist, Mozilla Firefox             ; find firefox
    {
        WinActivate                         ; use the window found above
        Sleep 500                           ; sleeps to allow SSH to transfer file
        Send ^r                             ; send browser refresh
        WinActivate, Aptana Studio 3        ; get back to Aptana
    }
}
else
{
    Send ^s                                 ; send save command
}
return
于 2011-07-07T20:52:05.153 回答
1

正如 democodemonkey 强烈建议的那样,您可以使用 Autohotkey。这是我的脚本示例。

^x::                  ; listen for a CTRL+x
   Send ^s               ; sends a CTRL+s save command to Eclipse
   Sleep 500             ; sleeps a bit to allow SSH to transfer file
   Send !{tab}^r         ; alt-tab followed by a browser refresh
   Sleep 100             ; firefox, needs just a bit to allow ALT-TAB
   Send !{tab}           ; tabs back to eclipse

这甚至比我想象的要好,因为我只需一个命令即可完成所有操作。非常令人印象深刻。再次感谢demoncodemonkey。

于 2009-09-25T13:23:46.420 回答