uBlockOrigin / uMatrix-issues

This is the community-maintained issue tracker for uMatrix
https://github.com/gorhill/uMatrix
123 stars 17 forks source link

Block/allow keyboard shortcuts/hotkeys #250

Closed ghost closed 4 years ago

ghost commented 4 years ago

Prerequisites

Description

Feature request: Add block/allow keyboard shortcuts/hotkeys of the page the user is on. Or is it out of scope for uMatrix because it's not a resource that gets loaded?

A specific URL where the issue occurs

Any page with keyboard shortcuts on it.

Steps to Reproduce

  1. Go to a page with keyboard shortcuts
  2. Notice inconvenience or be surprised shortcuts won't work (as expected)

Thanks a lot for uMatrix and your contributions to software freedom!

uBlock-user commented 4 years ago

Are you on Firefox ?

gorhill commented 4 years ago

Duplicate of https://github.com/gorhill/uMatrix/issues/678.

ghost commented 4 years ago

Hello, yes I am on Firefox. I don't think it matters though, because my suggestion was not to add shortcuts to control uMatrix, but to block or allow pages to overwrite browser shortcuts with their own custom ones.

I hope I'm not being annoying by replying, but I'm pretty sure this is a misunderstanding, as the linked supposed duplicate gorhill/uMatrix#678 is about shortcuts to control uMatrix.

gorhill commented 4 years ago

block or allow pages to overwrite browser shortcuts with their own custom ones.

I consider this out of scope for uMatrix. uMatrix can block JavaScript, which will prevent pages from setting up keyboard listeners, but blocking specific portions of JavaScript code is beyond uMatrix's scope.

gwarser commented 4 years ago

@WorldCodeCentral right click on page -> View Page Info -> Permissions -> Override Keyboard Shortcuts -> Block.

ghost commented 4 years ago

Thanks for your replies! Okay, so that's how keyboard shortcuts work.

Gwarser, thanks, I knew that one (and I think these permissions should have the same interface as cookies and camera, location, etc) but these block not only the page's but the extensions' shortcuts as well. Seems like the method to do that does not look for Javascript code but uses a switch for shortcut overwriting or something. I'm afraid it's not available for use in webextensions though. There's a ticket in bugzilla for that also.

Cheers!