gpt4 book ai didi

javascript - Chrome 扩展允许的键盘快捷键

转载 作者:行者123 更新时间:2023-11-29 17:00:44 25 4
gpt4 key购买 nike

当您创建 Chrome 浏览器扩展程序时,您可以通过实现 chrome.commands 来建议键盘快捷键应用程序接口(interface)。是否有记录的允许组合键列表? Chrome 似乎拒绝了我提供的几乎所有组合,尽管事实上我知道我所针对的任何系统都没有使用它们。

我知道列出的键盘快捷键 here , 但未出现在此列表中的快捷方式仍然不起作用。

最佳答案

文档是quite precise在这方面。我将引用文档,但请注意它可能会发生变化。此答案基于截至 2015-02-09 的文档

Supported keys: A-Z, 0-9, Comma, Period, Home, End, PageUp, PageDown, Space, Insert, Delete, Arrow keys (Up, Down, Left, Right) and the Media Keys (MediaNextTrack, MediaPlayPause, MediaPrevTrack, MediaStop).

Note: All key combinations must include either Ctrl* or Alt. Combinations that involve Ctrl+Alt are not permitted in order to avoid conflicts with the AltGr key. Shift can be used in addition to Alt or Ctrl, but is not required. Modifiers (such as Ctrl) can not be used in combination with the Media Keys. Tab key was removed from list of supported keys in Chrome version 33 and above for accessibility reasons.

  • Also note that on Mac 'Ctrl' is automatically converted to 'Command'. If you want 'Ctrl' instead, please specify 'MacCtrl'.

因此,一个组合必须包含 CtrlAlt不能同时包含,可选地包含 Shift 然后一个“支持的键”。

此外,

Certain Chrome shortcuts (e.g. window management) always take priority over Extension Command shortcuts and can not be overwritten.

这涵盖了 Chrome 在专注时收听的命令。对于系统级命令,仅限于Ctrl+Shift+(数字)

还有专门针对 Chrome 操作系统的附加规则,请阅读这些规则的相同文档。


另请注意,更改已安装扩展的建议键可能不会触发它们的分配。尝试重新安装扩展而不是在测试时重新加载它。

最后,正如 Whymarrh 所建议的,您可以在 chrome://extensions/shortcuts

中看到键绑定(bind)

关于javascript - Chrome 扩展允许的键盘快捷键,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28401138/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com