Go to comments ↓ Home » 软件心得

更新 Opera 代理切换菜单和按钮

opera杯具的上午,网络连不上,害我看不成比赛。直到3点多才恢复。

没事就折腾,把以前整过的 Opera 代理快速切换菜单 更新一下,解决几个小问题。
也可以准备迎接5月35号了,用到的机会更多。

本文纯粹是折腾回顾,不提供任何相关工具和网址,评论的同学们也请注意别出现关键词。

更新内容

  • 重写了 Pac 启用和禁用状态切换按钮的代码,现在打开标签较多的时候启用 Pac 不会再有停顿。
  • 修正了 Add To Exceptions (添加到例外)条目在 10.5x下会转到 null 页面的问题。
  • 简化了菜单,GTunnel 和 Puff 的条目默认不显示,启用/禁用 Pac的条目也不再需要了。
  • 添加 Mr.zhang 相关的条目,默认不显示。
  • Pac 切换菜单中添加本地 Pac文件的条目,需要修改路径。
  • 添加了一个在线代理,有备无患。

添加代理状态切换按钮

只有第二个有更新。

安装 Opera 代理快速切换菜单

在你的operaconfig菜单配置文件最后添加以下代码:

[Quick Proxy Menu]
Item, "Setting  »  Proxy"=External action,,,,Menu Tools | show preferences & show proxy servers
Item, "Add To Exceptions"=External action,,,,Add widget | edit site preferences & delay, 10 & copy & Cancel & delay,1 & Disable proxy servers & Show preferences & Show proxy servers & Delay, 10 & Check item & Focus next widget & Focus next widget & Focus next widget & Check item & Focus next widget & Focus next widget & Focus next widget & Focus next widget & Focus next widget & Focus next widget & Focus next widget & Focus next widget & Check item & Focus next widget & Go to end & Insert, "," & Paste & Ok & Delay, 10 & Cancel
Item, "Close » All Proxy"=execute program,"cmd.exe","/c taskkill /im opt* /f /t",,"Stop" & Disable proxy servers
Item, "---Fuck » GFW---"=Show popup menu
Item, "[召唤 » Fgate  ]"=Execute program,"fg的路径或快捷方式",,,"fg"
Item, "[召唤 » FreeU  ]"=Execute program,"fu的路径或快捷方式",,,"fu"
Item, "[召唤 » wujie  ]"=Execute program,"wj的路径或快捷方式",,,"u"
Item, "[召唤 » GApp   ]"=Execute program,"gapp的路径或快捷方式",,,"gap"
;Item, "[召唤 » GTunnel]"=Execute program,"gt的路径或快捷方式",,,"gt"
;Item, "[召唤 » Puff   ]"=Execute program,"puff的路径或快捷方式",,,"puff"
;Item, "[召唤 » Mr.Z   ]"=Execute program,"Mr.zhang的路径或快捷方式",,,"Panel Contacts"
Item, "[召唤 » SSH-D  ]"=Execute program,"myentunnel的路径或快捷方式" ,,,"p" & Execute program,"Privoxy/Polipo的快捷方式或启动脚本"
Item, "[召唤 » Tor    ]"=Execute program,"tor的路径或快捷方式",,,"tor"
BreakItem
Item, "Open in WebProxy 1"="Go to page, "https://imi.appspot.com/goto?url=%u",,,"Forward mail""
Item, "Open in WebProxy 2"="Go to page, "http://tor-proxy.net/proxy/express/browse.php?u=%u",,,"Forward mail""
Item, "Use » LocalPac"=disable proxy servers ,,,,"Lock panel" & Show preferences & Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"本地pac路径,绝对或相对均可" & focus next widget & Ok & Delay, 10 & Cancel
Submenu, "Use » OnlinePac", Pac Menu="Show popup menu,,,, "Restart transfer""
Item, "--Switch » Port--"=Show popup menu
Item, "[ Fg/fu ]  » 8580"=External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8580" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8580" & ok & delay,10 & cancel
Item, "[ Wujie ]  » 9666"=External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"9666" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"9666" & ok & delay,10 & cancel
Item, "[ GApp  ]  » 8000"=External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8000"  & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8000"  & ok & delay,10 & cancel
;Item, "[GTunnel]  » 8081"="External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8081" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8081" & ok & delay,10 & cancel"
;Item, "[ Puff  ]  » 1984"="External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"1984" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"1984" & ok & delay,10 & cancel"
;Item, "[ Mr.Z  ]  » 1984"="External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"2010" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"2010" & ok & delay,10 & cancel"
Item, "[Tor/SSH]  » 8118"=External action,,,,Panel Collapse Right | disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8118" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8118" & ok & delay,10 & cancel
Item, "Clipboard IP Port"=External action,,,,Mail Attachment | go to page, "opera:config#proxy|httpserver" & delay, 1000 & select all & paste & focus next widget & focus next widget & paste & focus address field & insert, "opera:config#proxy" & go & focus previous widget & focus previous widget & click button & delay, 10 & ok & delay,1 &close page

[Pac Menu]
Item, "[9666 »  Wujie ]"=disable proxy servers,,,,"u" & Show preferences& Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"http://autoproxy2pac.appspot.com/pac/wu-jie" & focus next widget & Ok & Delay, 10 & Cancel
Item, "[8580 »  Fg/Fu ]"=disable proxy servers ,,,,"fg" & Show preferences& Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"http://autoproxy2pac.appspot.com/pac/free-gate" & focus next widget & Ok & Delay, 10 & Cancel
Item, "[8000 »   Gapp ]"=disable proxy servers ,,,,"gap" & Show preferences& Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"http://autoproxy2pac.appspot.com/pac/gappproxy" & focus next widget & Ok & Delay, 10 & Cancel
;Item, "[1984 »   Puff ]"=disable proxy servers ,,,,"puff" &Show preferences& Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"http://autoproxy2pac.appspot.com/pac/puff" & focus next widget & Ok & Delay, 10 & Cancel
;Item, "[8081 » GTunnel]"=disable proxy servers ,,,,"gt" & Show preferences & Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"http://autoproxy2pac.appspot.com/pac/proxy/127.0.0.1/8081" & focus next widget & Ok & Delay, 10 & Cancel
Item, "[8118 » SSH/Tor]"=disable proxy servers ,,,,"p" & Show preferences& Show proxy servers & Focus previous widget & Focus previous widget & Focus previous widget & Focus previous widget & Check item & Focus next widget & Insert,"http://autoproxy2pac.appspot.com/pac/privoxy" & focus next widget & Ok & Delay, 10 & Cancel

[Quick Proxy Patch]
Item, "[切换到9666 并召唤 wujie]"=External action,,,,"u" | Execute program,"wj的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"9666" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"9666" & ok & delay,10 & cancel
Item, "[切换到8580 并召唤 Fgate]"=External action,,,,"fg" | Execute program,"fg的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8580" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8580" & ok & delay,10 & cancel
Item, "[切换到8580 并召唤 FreeU]"=External action,,,,"fu" | Execute program,"fu的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show prox servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8580" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8580" & ok & delay,10 & cancel
Item, "[切换到8000 并召唤  GApp]"=External action,,,,"gap" | Execute program,"Gapp的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8000"  & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8000"  & ok & delay,10 & cancel
;Item, "[切换到1984 并召唤  Puff]"=External action,,,,"puff" | Execute program,"puff的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"1984" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"1984" & ok & delay,10 & cancel
Item, "[切换到8118 并召唤 SSH-D]"=External action,,,,"p" | Execute program,"myentunnel的路径或快捷方式" & delay,20 & Execute program,"Privoxy/Polipo的快捷方式或召唤脚本" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8118" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8118" & ok & delay,10 & cancel
Item, "[切换到8118 并召唤   Tor]"=External action,,,,"tor" | Execute program,"Tor的路径或快捷方式" & delay,20 & Execute program,"Privoxy/Polipo的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8118" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8118" & ok & delay,10 & cancel
;Item, "[切换到8081并召唤GTunnel]"=External action,,,,"gt" | Execute program,"Gtunnel的路径或快捷方式" & delay,20 & disable proxy servers & show preferences & show proxy servers & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8081" & focus next widget & check item & focus next widget & insert,"127.0.0.1" & focus next widget & insert,"8081" & ok & delay,10 & cancel

代理菜单使用说明

  • 图标添加和详细说明请查看:《轻松用代理:打造豪华Opera代理菜单
  • 修改菜单时,要注意保存为UTF-8无BOM格式,否则会乱码。
  • 注意在保存menu 、skin之前,要先关闭Opera。
  • 如果提示“此扩展名未注册应用程序”,那么请检查外部程序路径。

后续更新:

» 转载请以超链接形式注明来源:A.shun Blog » 《更新 Opera 代理切换菜单和按钮》
» 本文链接地址:http://www.a-shun.com/archives/21362.html

» 本文采用 BY-NC-SA 协议进行授权。
» 建议通过 Rss( Google Reader | Feedburner | Feedsky )方式及时获取更新。
  1. “XXX的路径或快捷方式”怎么确定?例如,是wj的路径或快捷方式,那么wj是放在OPERA的什么文件夹下的?

    Opera 10.60 Opera 10.60 Windows XP Windows XP
    #41
    @
    • @opera
      举个例子吧,放在假设放在D:\Web\Opera\tools\中,名字是wj.exe
      那么填写D:\Web\Opera\tools\wj.exe 这是绝对路径。
      也可以用tools\wj.exe,这是相对路径。

      如果只是用绝对路径的话,不放op目录下也行

      Opera 10.70 Opera 10.70 Windows XP Windows XP
  2. A.shun :@opera 举个例子吧,放在假设放在D:\Web\Opera\tools\中,名字是wj.exe 那么填写D:\Web\Opera\tools\wj.exe 这是绝对路径。 也可以用tools\wj.exe,这是相对路径。如果只是用绝对路径的话,不放op目录下也行

    Item, “[召唤 » Fgate ]“=Execute program,”fg的路径或快捷方式”,,,”fg”
    以你写的为例好了,我的意思是怎么找到fg的安装目录,我在op目录下找不到啊,而这个fg是指一个什么格式文件。我不懂哦,求教!OPZ!

    Opera 10.60 Opera 10.60 Windows XP Windows XP
    #42
    @
    • @opera fg和wj那是就是代理工具的程序名嘛。不属于 Opera 的,你要自己下载。
      这个是敏感词,如果你有这个需求,就搜索下。

      Opera 10.70 Opera 10.70 Windows XP Windows XP
    • @A.shun 能问下EasyTor是不是没用了?

      Opera 10.60 Opera 10.60 Windows XP Windows XP
  3. A.shun :@opera fg和wj那是就是代理工具的程序名嘛。不属于 Opera 的,你要自己下载。 这个是敏感词,如果你有这个需求,就搜索下。

    哦,十分感谢你的解答!

    Opera 10.60 Opera 10.60 Windows XP Windows XP
    #43
    @
Leave a Reply

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: