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

Side by Side Diff: Source/devtools/front_end/CodeMirrorUtils.js

Issue 216973004: DevTools: roll CodeMirror to v4.0.3 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: support autocomplete with multiselections Created 6 years, 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 var codeMirror = window.CodeMirror(element, { 65 var codeMirror = window.CodeMirror(element, {
66 mode: config.mode, 66 mode: config.mode,
67 lineWrapping: config.lineWrapping, 67 lineWrapping: config.lineWrapping,
68 smartIndent: config.smartIndent, 68 smartIndent: config.smartIndent,
69 autofocus: true, 69 autofocus: true,
70 theme: config.theme, 70 theme: config.theme,
71 value: config.initialValue 71 value: config.initialValue
72 }); 72 });
73 codeMirror.getWrapperElement().classList.add("source-code"); 73 codeMirror.getWrapperElement().classList.add("source-code");
74 codeMirror.on("cursorActivity", function(cm) { 74 codeMirror.on("cursorActivity", function(cm) {
75 cm.display.cursor.scrollIntoViewIfNeeded(false); 75 cm.display.cursorDiv.scrollIntoViewIfNeeded(false);
76 }); 76 });
77 editingContext.codeMirror = codeMirror; 77 editingContext.codeMirror = codeMirror;
78 }, 78 },
79 79
80 closeEditor: function(editingContext) 80 closeEditor: function(editingContext)
81 { 81 {
82 editingContext.element.removeEventListener("copy", this._consumeCopy, fa lse); 82 editingContext.element.removeEventListener("copy", this._consumeCopy, fa lse);
83 editingContext.cssLoadView.detach(); 83 editingContext.cssLoadView.detach();
84 }, 84 },
85 85
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 { 144 {
145 WebInspector.VBox.call(this); 145 WebInspector.VBox.call(this);
146 this.element.classList.add("hidden"); 146 this.element.classList.add("hidden");
147 this.registerRequiredCSS("cm/codemirror.css"); 147 this.registerRequiredCSS("cm/codemirror.css");
148 this.registerRequiredCSS("cm/cmdevtools.css"); 148 this.registerRequiredCSS("cm/cmdevtools.css");
149 } 149 }
150 150
151 WebInspector.CodeMirrorCSSLoadView.prototype = { 151 WebInspector.CodeMirrorCSSLoadView.prototype = {
152 __proto__: WebInspector.VBox.prototype 152 __proto__: WebInspector.VBox.prototype
153 } 153 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/CodeMirrorTextEditor.js ('k') | Source/devtools/front_end/cm/closebrackets.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698