Change edit shortcut from 'm' to 'e'

I keep missing the shift key when typing shift-m to mark a file
as reviewed and move to next file. With 'm' bound to open file in
editor this is launching me into the edit screen, which is annoying
to get out of.

Swap to 'e' which is currently not bound to anything.

Change-Id: Ia92e1b71cda34bd7d5fd77e8d0423670114e1a0c
This commit is contained in:
Shawn Pearce
2015-03-26 12:16:31 -07:00
parent 4ef1521d90
commit cb9cc54762
3 changed files with 6 additions and 7 deletions

View File

@@ -371,7 +371,7 @@ public class SideBySide extends Screen {
.on("O", commentManager.toggleOpenBox(cm))
.on("Enter", commentManager.toggleOpenBox(cm))
.on("N", maybeNextVimSearch(cm))
.on("M", modifyInEditScreen(cm))
.on("E", openEditScreen(cm))
.on("P", chunkManager.diffChunkNav(cm, Direction.PREV))
.on("Shift-A", diffTable.toggleA())
.on("Shift-M", header.reviewedAndNext())
@@ -486,9 +486,9 @@ public class SideBySide extends Screen {
new NoOpKeyCommand(KeyCommand.M_SHIFT, 'p', PatchUtil.C.commentPrev()));
keysNavigation.add(
new NoOpKeyCommand(KeyCommand.M_CTRL, 'f', Gerrit.C.keySearch()));
keysNavigation.add(
new NoOpKeyCommand(0, 'm', PatchUtil.C.modifyInEditScreen()));
keysAction = new KeyCommandSet(Gerrit.C.sectionActions());
keysAction.add(new NoOpKeyCommand(0, 'e', PatchUtil.C.openEditScreen()));
keysAction.add(new NoOpKeyCommand(0, KeyCodes.KEY_ENTER,
PatchUtil.C.expandComment()));
keysAction.add(new NoOpKeyCommand(0, 'o', PatchUtil.C.expandComment()));
@@ -938,7 +938,7 @@ public class SideBySide extends Screen {
}
}
private Runnable modifyInEditScreen(final CodeMirror cm) {
private Runnable openEditScreen(final CodeMirror cm) {
return new Runnable() {
@Override
public void run() {

View File

@@ -58,7 +58,7 @@ public interface PatchConstants extends Constants {
String toggleIntraline();
String showPreferences();
String modifyInEditScreen();
String openEditScreen();
String toggleReviewed();
String markAsReviewedAndGoToNext();

View File

@@ -40,8 +40,7 @@ toggleSideA = Toggle left side
toggleIntraline = Toggle intraline difference
showPreferences = Show diff preferences
modifyInEditScreen = Modify in edit screen
openEditScreen = Edit file in browser
toggleReviewed = Toggle the reviewed flag
markAsReviewedAndGoToNext = Mark patch as reviewed and go to next unreviewed patch