Files
gerrit/lib/codemirror/cm.defs
David Ostrovsky 99d8d3c21f InlineEdit: Switch to using native jump-to-line addon
The feature request to add native jump-to-line dialog to CodeMirror: [1]
was solved in context of this PR: [2]. So that now we can switch from
native and ugly Window#prompt() to nice looking CodeMirror addon.

Test Plan:

- Open change editor
- Type Alt-G|Ctrl-L|Cmd-L
- Jump to line dialog appears
- Type the line number: 42 and hit enter
- Confirm that the cursor is jumped to line 42

[1] https://github.com/codemirror/CodeMirror/issues/3030
[2] https://github.com/codemirror/CodeMirror/pull/3682

Change-Id: Ic9b889ea1efe26b3a19c5e885f1668009acc12ad
2016-02-10 09:12:14 +00:00

90 lines
1.5 KiB
Plaintext

CM_CSS = [
'lib/codemirror.css',
'addon/dialog/dialog.css',
'addon/scroll/simplescrollbars.css',
'addon/search/matchesonscrollbar.css',
]
CM_JS = [
'lib/codemirror.js',
'mode/meta.js',
'keymap/vim.js',
'keymap/emacs.js',
]
CM_ADDONS = [
'dialog/dialog.js',
'edit/closebrackets.js',
'edit/matchbrackets.js',
'edit/trailingspace.js',
'scroll/annotatescrollbar.js',
'scroll/simplescrollbars.js',
'search/jump-to-line.js',
'search/matchesonscrollbar.js',
'search/searchcursor.js',
'search/search.js',
'selection/mark-selection.js',
'mode/overlay.js',
'mode/simple.js',
]
# Available themes must be enumerated here,
# in gerrit-extension-api/src/main/java/com/google/gerrit/extensions/common/Theme.java,
# in gerrit-gwtui/src/main/java/net/codemirror/theme/Themes.java
CM_THEMES = [
'eclipse',
'elegant',
'midnight',
'neat',
'night',
'twilight',
]
# Available modes must be enumerated here,
# in gerrit-gwtui/src/main/java/net/codemirror/mode/Modes.java,
# and in CodeMirror's own mode/meta.js script.
CM_MODES = [
'clike',
'clojure',
'coffeescript',
'commonlisp',
'css',
'd',
'dart',
'diff',
'dockerfile',
'dtd',
'erlang',
'gas',
'gfm',
'go',
'groovy',
'haskell',
'htmlmixed',
'javascript',
'lua',
'markdown',
'perl',
'php',
'pig',
'properties',
'puppet',
'python',
'r',
'rst',
'ruby',
'scheme',
'shell',
'smalltalk',
'soy',
'sql',
'stex',
'swift',
'tcl',
'velocity',
'verilog',
'vhdl',
'xml',
'yaml',
]