Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Process of Inserting Alt Code Reveals Toolbar #4295

Closed
jonathansampson opened this issue Sep 25, 2016 · 11 comments
Closed

Process of Inserting Alt Code Reveals Toolbar #4295

jonathansampson opened this issue Sep 25, 2016 · 11 comments

Comments

@jonathansampson
Copy link
Collaborator

jonathansampson commented Sep 25, 2016

Did you search for similar issues before submitting this one?

Yes

Describe the issue you encountered:

Typing certain characters from a Windows machine sometimes requires the use of the Alt key. This key is currently configured to toggle the Toolbar. Holding Alt and typing 0133 on the Number Pad causes the toolbar to be revealed.

Expected behavior:

Inserting ALT Codes does not cause the toolbar to be revealed.

  • Platform (Win7, 8, 10? macOS? Linux distro?): Windows 10
  • Brave Version: 0.12.2
  • Steps to reproduce:
    1. Focus on an input
    2. Hold Alt and type 0133 into Number Pad
    3. Note that toolbar has been revealed
  • Relevant LOC: .../js/components/main.js#L133
  • Screenshot if needed:
  • Any related issues:
@willy-b
Copy link
Contributor

willy-b commented Sep 25, 2016

Does fixing this bug mean pressing Alt will no longer reveal the toolbar? I really like that feature :-)

@jonathansampson
Copy link
Collaborator Author

@willy-b, no. I think we should extend the functionality to better accommodate the entering of alt codes.

@jonathansampson
Copy link
Collaborator Author

Another scenario where this causes issues with with per-window screenshots on Windows.

To take a screenshot of an application window on Windows, you focus that window, hold Alt, and press PrtScn. Upon doing this, the window screenshot is copied to your clipboard, and (unexpectedly) the toolbar for Brave is opened.

@srirambv
Copy link
Collaborator

srirambv commented Sep 26, 2016

Also happens when you press Ctrl+Alt+U to view page source and release the keys

@toxiicdev
Copy link

Yea it happens even when you're writing your email and you are going to type @ character (in IT keyboard it is ALT + ;)

@bsclifton
Copy link
Member

bsclifton commented Oct 20, 2016

This should be fixed now... one of the problems when I added this was not differentiating between the left (ALT) and right (ALTGR) keys. @toxiicdev are you using the latest Brave version, 0.12.5? Please let me know

Thanks! 😄
(edit: issue was fixed with #4626)

@toxiicdev
Copy link

toxiicdev commented Oct 20, 2016

@bsclifton Yep I'm using 0.12.5, I'll try now

Edit: Works fine now !

@srirambv
Copy link
Collaborator

srirambv commented Nov 3, 2016

Closing the dev console via keyboard shortcut also shows the menu toolbar

filemenu

@jonathansampson
Copy link
Collaborator Author

@bsclifton For this issue, could we keep a simple record of the last key pressed (lastKey), and toggle the toolbar on the keyup event when both lastKey and event.key are both "Alt"?

@bsclifton
Copy link
Member

@jonathansampson that would totally work 😄

@jonathansampson
Copy link
Collaborator Author

This issue was called out on Twitter for being a nuisance when back-forward browsing with the ALT key: https://twitter.com/livebeef/status/795344401132298240

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

No branches or pull requests

6 participants