JSS Keyboard Shortcuts Bug with Chrome on Mac, Multiple Browsers on Windows


I've been seeing weird behavior for quite some time in the JSS (9.97 in our environment, though I've tested with the latest 9.x release), when using Chrome on Macs. I'll be typing in a text field and when I press the letters "c" or "s" it will cancel or save whatever I'm doing (generally editing policies) as if I had pressed Control+C or Control+S outside a text field. I think I've narrowed it down, and I was wondering if anyone else has seen or can reproduce this...

If you have Chrome installed, try the following steps to see if you can replicate it:

  1. Open multiple tabs to some random sites in a Google Chrome window.
  2. Go to the JSS in one of the tabs and open a policy—for testing purposes, pick one you don’t care about that much, just to be safe.
  3. Edit the policy, then switch away from this tab using Control+Tab, and then go back to the policy tab (using any method).
  4. Click in a text field like Display Name (if cursor not already in text field) and type the letters “abc”.

If your Mac behaves like mine, as soon as you press the “c” in “abc” it will cancel the policy edit as if you had pressed Control+C. The bug does not depend on being in the text field, but that’s the most common way I encounter it, and it sucks because I could be making all kinds of edits and then I’m in a text field and type the letter “c” and it undoes all of it!

The key to “activating” this bug seems to be Control+Tabbing away from a JSS tab. Then when you go back to that particular tab—even after a while—JSS keyboard shortcut that would normally require pressing Control to use will instead trigger just by pressing the letter (“c” for cancel, “s” for save, “d” for delete).

As another test, try Control+Tabbing away from a JSS tab, going back to the JSS tab (however you like), and pressing “d”. It should prompt if you want to delete the policy/script/etc. (assuming the tab was on a JSS page that had a Delete button for whatever item it was on).

To cancel the activation of the bug, I can either press the Control key once or refresh the page. For example, if I Control+Tab away from a tab with a JSS policy, go back to the tab, press “e” to edit the policy, going into edit mode is enough to refresh, and then typing “abc” in a text field won’t trigger it, which is why in the test above I have you go into edit mode in a policy first, then tab away.

The bug does not appear to activate on a JSS tab when Control+tabbing to it.

This bug does not seem to affect Safari or Firefox for Mac, but I can replicate it on Windows with all three major browsers: Chrome, Firefox, Internet Explorer. On Windows, JSS keyboard shortcuts use Alt, so if I Alt+Tab to another application and then back to the browser, then the bug will “activate” if the active tab in the browser is a JSS tab. Pressing the Alt key will cancel the activation of the bug in Chrome and IE, but not in Firefox on Windows.