Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(752)

Unified Diff: third_party/WebKit/Source/devtools/front_end/text_editor/CodeMirrorTextEditor.js

Issue 2760583002: DevTools: Don't give up autocomplete after a fancy character in a string (Closed)
Patch Set: merge Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/text_editor/CodeMirrorTextEditor.js
diff --git a/third_party/WebKit/Source/devtools/front_end/text_editor/CodeMirrorTextEditor.js b/third_party/WebKit/Source/devtools/front_end/text_editor/CodeMirrorTextEditor.js
index 41d0d9ba36d49fce89744efb2f175f76520b572d..5dc4134aafaac5b7ab68f6fe0c6d7d5ed68e041d 100644
--- a/third_party/WebKit/Source/devtools/front_end/text_editor/CodeMirrorTextEditor.js
+++ b/third_party/WebKit/Source/devtools/front_end/text_editor/CodeMirrorTextEditor.js
@@ -626,14 +626,15 @@ TextEditor.CodeMirrorTextEditor = class extends UI.VBox {
}
/**
+ * @override
* @param {number} lineNumber
- * @param {number} column
+ * @param {number} columnNumber
* @return {?{startColumn: number, endColumn: number, type: string}}
*/
- tokenAtTextPosition(lineNumber, column) {
+ tokenAtTextPosition(lineNumber, columnNumber) {
if (lineNumber < 0 || lineNumber >= this._codeMirror.lineCount())
return null;
- var token = this._codeMirror.getTokenAt(new CodeMirror.Pos(lineNumber, (column || 0) + 1));
+ var token = this._codeMirror.getTokenAt(new CodeMirror.Pos(lineNumber, (columnNumber || 0) + 1));
if (!token)
return null;
return {startColumn: token.start, endColumn: token.end, type: token.type};

Powered by Google App Engine
This is Rietveld 408576698