Add preference to disable all keyboard shortcuts

Add a user preference to disable usage of all keyboard shortcuts.
The preference will help avoid certain bugs such as incorrectly
starring a change(Issue 13802).
GMail also supports such a setting.

Bug: Issue 13571
Change-Id: I65c5410406638de7b6e55b5518b374c8bfdafc29
This commit is contained in:
Dhruv Srivastava
2020-12-21 18:18:20 +01:00
parent 903a717498
commit a5867c0c04
2 changed files with 4 additions and 0 deletions

View File

@@ -2816,6 +2816,8 @@ Allowed values are `ENABLED`, `CC_ON_OWN_COMMENTS`, `ATTENTION_SET_ONLY`,
The base which should be pre-selected in the 'Diff Against' drop-down
list when the change screen is opened for a merge commit.
Allowed values are `AUTO_MERGE` and `FIRST_PARENT`.
|`disable_keyboard_shortcuts` |not set if `false`|
Whether to disable all keyboard shortcuts.
|`publish_comments_on_push` |not set if `false`|
Whether to link:user-upload.html#publish-comments[publish draft comments] on
push by default.

View File

@@ -147,6 +147,7 @@ public class GeneralPreferencesInfo {
public EmailFormat emailFormat;
public DefaultBase defaultBaseForMerges;
public Boolean publishCommentsOnPush;
public Boolean disableKeyboardShortcuts;
public Boolean workInProgressByDefault;
public List<MenuItem> my;
public List<String> changeTable;
@@ -205,6 +206,7 @@ public class GeneralPreferencesInfo {
p.emailFormat = EmailFormat.HTML_PLAINTEXT;
p.defaultBaseForMerges = DefaultBase.FIRST_PARENT;
p.publishCommentsOnPush = false;
p.disableKeyboardShortcuts = false;
p.workInProgressByDefault = false;
return p;
}