Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 371914 - keybinding collision for editor and key assist
Summary: keybinding collision for editor and key assist
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 0.4   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 0.4 RC3   Edit
Assignee: Mark Macdonald CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-02-17 12:55 EST by Susan McCourt CLA
Modified: 2013-09-24 15:04 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Susan McCourt CLA 2012-02-17 12:55:56 EST
When I fixed bug 366445 I forgot that Shift+Ctrl+/ is used for "add block comment" in the editor.  

This collision is on non-Macs.
One possibility is Shift+Alt+Ctrl?
we need to consider:

- common browser bindings
- common platform bindings
- our editor bindings
- popular (textmate, etc.) editor bindings
Comment 1 Susan McCourt CLA 2012-02-21 14:53:27 EST
mark is taking this for me (thanks!)
Comment 2 Mark Macdonald CLA 2012-02-21 18:21:18 EST
Here's a patch that moves Key Assist (on non-Mac platforms) to Alt+Shift+? when you're inside the editor. This doesn't appear to collide with any browser or platform keys. On Mac OS, Key Assist remains Ctrl+Shift+/ (I considered changing it to match the non-Mac one, but Alt+Shift+x shortcuts are reserved by OS X for entering special characters so this was a no-go).

On the Mac, to avoid clobbering the "Show Help menu" shortcut, I've moved Add Block Comment to Ctrl+Cmd+/ and Remove Block Comment to Ctrl+Cmd+\. This also matches the Eclipse desktop keybindings for these commands. 

The branch is here:
http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?h=bug371914_blockcomment2
Comment 3 Susan McCourt CLA 2012-02-21 21:32:45 EST
+1.
Tested in Win7/Chrome, Win7/FF, and Mac/Safari.
Restating for my own understanding.

Win7/Chrome and FF:
Key assist is now (Shift+Alt+/) which is (Alt+?) so we no longer collide with add block comment.
Add block comment remains at (Ctrl+Shift+/)

Mac/Safari
Key assist remains at (Ctrl+Shift+/) which is (Ctrl+?).  (As Mark explained, Alt+Shift is used by OSX so we can't be consistent with the new non-Mac binding)
Add block comment is now (Cmd+Ctrl+/) and Remove block comment is (Cmd+Ctrl+|)
instead of (Cmd+Shift+/) and (Cmd+Shift+|).  


The only oddity I observed is that on Win7/Chrome, when you use (Shift+Alt+/) to get key assist, you get a beep.  This beep occurs before and after the fix, it just happens that you get a key assist panel along with the free beep after the fix.  This makes me think there's some mnemonic or keybinding on chrome that could have done something with (Shift+Alt+/) but could not.  Given that the key assist is not a commonly used key, I think we go with this for now.  If we were getting beeps with an important editor key binding, I'd want to investigate further.
Comment 4 Susan McCourt CLA 2012-02-21 21:33:20 EST
Ken, ok for RC3?  
I tested and reviewed the code.  Did not push since there was no signoff yet on this bug.
Comment 5 Ken Walker CLA 2012-02-21 22:24:31 EST
As a project lead I +1 this change for RC3
Comment 6 Susan McCourt CLA 2012-02-21 22:34:04 EST
pushed fix.
Ken and I aren't sure if the push happened before checkout for the build.  This fix may or may not be in the build that's happening right now.
Comment 7 Mark Macdonald CLA 2012-02-21 22:42:37 EST
(In reply to comment #3)
> The only oddity I observed is that on Win7/Chrome, when you use (Shift+Alt+/)
> to get key assist, you get a beep.  This beep occurs before and after the fix,
> it just happens that you get a key assist panel along with the free beep after
> the fix.  This makes me think there's some mnemonic or keybinding on chrome
> that could have done something with (Shift+Alt+/) but could not.  Given that
> the key assist is not a commonly used key, I think we go with this for now.  If
> we were getting beeps with an important editor key binding, I'd want to
> investigate further.

Gah, I had the system sounds muted so I didn't notice this. Alt+/ produces the same beep. Doesn't appear to actually do anything, so I guess it's a bug in Chrome. How annoying...
Comment 8 Mark Macdonald CLA 2012-02-21 22:44:01 EST
Bugzilla helpfully made my comment reopen this bug. Thanks Bugzilla.
Comment 9 Carolyn MacLeod CLA 2013-04-29 15:07:34 EDT
Just FYI, I typed an explanation for the beep in the Chrome bug:
https://code.google.com/p/chromium/issues/detail?id=105500#c10

Currently, nobody "owns" that bug, so if you have a moment to sign in and "star" (aka "vote for") it, that would be appreciated.