Revert "InlineEdit: Switch to using native jump-to-line addon"
This reverts commit 99d8d3c21f
.
We need to revert the CodeMirror upgrade to 5.11 which was done by
Id02e65 because it broke displaying the file diff for certain files as
reported by issue 3927 [1]. Since this commit relies on the new
CodeMirror version is must be reverted as well.
[1] https://code.google.com/p/gerrit/issues/detail?id=3927
Change-Id: I6b15aa239666348e5c4ac50f4b248ef9a8f00cc5
This commit is contained in:
@@ -257,7 +257,20 @@ public class EditScreen extends Screen {
|
||||
return new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
cm.execCommand("jumpToLine");
|
||||
String n = Window.prompt(EditConstants.I.gotoLineNumber(), "");
|
||||
if (n != null) {
|
||||
try {
|
||||
int line = Integer.parseInt(n);
|
||||
line--;
|
||||
if (line >= 0) {
|
||||
cm.scrollToLine(line);
|
||||
}
|
||||
} catch (NumberFormatException e) {
|
||||
// ignore non valid numbers
|
||||
// We don't want to popup another ugly dialog just to say
|
||||
// "The number you've provided is invalid, try again"
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@@ -19,7 +19,6 @@ CM_ADDONS = [
|
||||
'edit/trailingspace.js',
|
||||
'scroll/annotatescrollbar.js',
|
||||
'scroll/simplescrollbars.js',
|
||||
'search/jump-to-line.js',
|
||||
'search/matchesonscrollbar.js',
|
||||
'search/searchcursor.js',
|
||||
'search/search.js',
|
||||
|
Reference in New Issue
Block a user