Chromium Code Reviews| 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 ee0ec96ec454fb6b1855e98e97729403b6b427f0..224dbebd3b151a72ce62e457fa0cb8a9e033b7bc 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 |
| @@ -1022,8 +1022,10 @@ TextEditor.CodeMirrorTextEditor = class extends UI.VBox { |
| return; |
| // We do not show "scroll beyond end of file" span for one line documents, so we need to check if "document has one line" changed. |
| var hasOneLine = this._codeMirror.lineCount() === 1; |
| - if (hasOneLine !== this._hasOneLine) |
| + if (hasOneLine !== this._hasOneLine) { |
| this._resizeEditor(); |
| + this.widget().invalidateSize(); |
|
einbinder
2016/12/13 19:35:30
this.widget() actually returns this.
this.invalida
|
| + } |
| this._hasOneLine = hasOneLine; |
| this._decorations.valuesArray().forEach(decoration => this._codeMirror.removeLineWidget(decoration.widget)); |