Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(shortcut): 增加浏览器内全局快捷键的功能 #146

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

mu-yu
Copy link

@mu-yu mu-yu commented May 22, 2018

上一曲<C-S-Left>、下一曲<C-S-Right>、播放/暂停<C-S-Up>

 上一曲<C-S-Left>、下一曲<C-S-Right>、播放/暂停<C-S-Up>
@listen1
Copy link
Owner

listen1 commented Jun 8, 2018

非常感谢你的提交。全局快捷键是非常有用的功能。
个人觉得可能在增加此功能的同时能够提供用户修改全局快捷键的设置界面,这样更方便普通用户解决快捷键冲突,以及提示全局快捷键的设置。

@mu-yu
Copy link
Author

mu-yu commented Jun 12, 2018

我这个pr中的方式来添加全局快捷键的话只能控制是否启用,无法做到在扩展内设置键位…如果要设置键位,需要引导用户去浏览器指定的页面去设置,chrome下是chrome://extensions/shortcuts,firefox不常用了不太清楚…

也可以设置监听所有页面,然后利用contentScript和background.js通信来设置全局快捷键,但是这样子就需要监听所有页面<all_urls>,而且特殊页面如chrome协议的页面、加载失败的页面、其它扩展页面等无法使用快捷键。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants