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

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

Issue 13845021: DevTools: Bring Sass support from behind the experiment (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Comments addressed Created 7 years, 5 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
« no previous file with comments | « Source/devtools/front_end/Settings.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 294 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebIns pector.UIString("Show FPS meter"), WebInspector.settings.showFPSCounter, false, this._showFPSCheckbox)); 305 this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebIns pector.UIString("Show FPS meter"), WebInspector.settings.showFPSCounter, false, this._showFPSCheckbox));
306 this._continousPaintingCheckbox = document.createElement("input"); 306 this._continousPaintingCheckbox = document.createElement("input");
307 this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebIns pector.UIString("Enable continuous page repainting"), WebInspector.settings.cont inuousPainting, false, this._continousPaintingCheckbox)); 307 this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebIns pector.UIString("Enable continuous page repainting"), WebInspector.settings.cont inuousPainting, false, this._continousPaintingCheckbox));
308 this._showScrollBottleneckRectsCheckbox = document.createElement("input"); 308 this._showScrollBottleneckRectsCheckbox = document.createElement("input");
309 var tooltip = WebInspector.UIString("Shows areas of the page that slow down scrolling:\nTouch and mousewheel event listeners can delay scrolling.\nSome area s need to repaint their content when scrolled."); 309 var tooltip = WebInspector.UIString("Shows areas of the page that slow down scrolling:\nTouch and mousewheel event listeners can delay scrolling.\nSome area s need to repaint their content when scrolled.");
310 this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebIns pector.UIString("Show potential scroll bottlenecks"), WebInspector.settings.show ScrollBottleneckRects, false, this._showScrollBottleneckRectsCheckbox, tooltip)) ; 310 this._compositingModeSettings.appendChild(this._createCheckboxSetting(WebIns pector.UIString("Show potential scroll bottlenecks"), WebInspector.settings.show ScrollBottleneckRects, false, this._showScrollBottleneckRectsCheckbox, tooltip)) ;
311 this._forceCompositingModeChanged(); 311 this._forceCompositingModeChanged();
312 312
313 p = this._appendSection(WebInspector.UIString("Sources")); 313 p = this._appendSection(WebInspector.UIString("Sources"));
314 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Search in c ontent scripts"), WebInspector.settings.searchInContentScripts)); 314 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Search in c ontent scripts"), WebInspector.settings.searchInContentScripts));
315 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Enable sour ce maps"), WebInspector.settings.sourceMapsEnabled)); 315 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Enable JS s ource maps"), WebInspector.settings.jsSourceMapsEnabled));
316 if (WebInspector.experimentsSettings.isEnabled("sass")) 316 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Enable CSS source maps"), WebInspector.settings.cssSourceMapsEnabled));
317 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Auto-re load CSS upon Sass save"), WebInspector.settings.cssReloadEnabled)); 317 WebInspector.settings.cssSourceMapsEnabled.addChangeListener(this._cssSource MapsEnablementChanged, this);
318 this._cssSourceMapSettings = p.createChild("fieldset");
319 var autoReloadCSSCheckbox = this._cssSourceMapSettings.createChild("input");
320 this._cssSourceMapSettings.appendChild(this._createCheckboxSetting(WebInspec tor.UIString("Auto-reload generated CSS"), WebInspector.settings.cssReloadEnable d, false, autoReloadCSSCheckbox));
321 this._cssSourceMapsEnablementChanged();
322
318 var indentationElement = this._createSelectSetting(WebInspector.UIString("In dentation"), [ 323 var indentationElement = this._createSelectSetting(WebInspector.UIString("In dentation"), [
319 [ WebInspector.UIString("Auto-detect"), WebInspector.TextUtils.Inden t.AutoDetect ], 324 [ WebInspector.UIString("Auto-detect"), WebInspector.TextUtils.Inden t.AutoDetect ],
320 [ WebInspector.UIString("2 spaces"), WebInspector.TextUtils.Indent.T woSpaces ], 325 [ WebInspector.UIString("2 spaces"), WebInspector.TextUtils.Indent.T woSpaces ],
321 [ WebInspector.UIString("4 spaces"), WebInspector.TextUtils.Indent.F ourSpaces ], 326 [ WebInspector.UIString("4 spaces"), WebInspector.TextUtils.Indent.F ourSpaces ],
322 [ WebInspector.UIString("8 spaces"), WebInspector.TextUtils.Indent.E ightSpaces ], 327 [ WebInspector.UIString("8 spaces"), WebInspector.TextUtils.Indent.E ightSpaces ],
323 [ WebInspector.UIString("Tab character"), WebInspector.TextUtils.Ind ent.TabCharacter ] 328 [ WebInspector.UIString("Tab character"), WebInspector.TextUtils.Ind ent.TabCharacter ]
324 ], WebInspector.settings.textEditorIndent); 329 ], WebInspector.settings.textEditorIndent);
325 indentationElement.firstChild.className = "toplevel"; 330 indentationElement.firstChild.className = "toplevel";
326 p.appendChild(indentationElement); 331 p.appendChild(indentationElement);
327 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show whites pace characters"), WebInspector.settings.showWhitespacesInEditor)); 332 p.appendChild(this._createCheckboxSetting(WebInspector.UIString("Show whites pace characters"), WebInspector.settings.showWhitespacesInEditor));
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 this._showScrollBottleneckRectsCheckbox.checked = false; 376 this._showScrollBottleneckRectsCheckbox.checked = false;
372 WebInspector.settings.showFPSCounter.set(false); 377 WebInspector.settings.showFPSCounter.set(false);
373 WebInspector.settings.continuousPainting.set(false); 378 WebInspector.settings.continuousPainting.set(false);
374 WebInspector.settings.showDebugBorders.set(false); 379 WebInspector.settings.showDebugBorders.set(false);
375 WebInspector.settings.showScrollBottleneckRects.set(false); 380 WebInspector.settings.showScrollBottleneckRects.set(false);
376 } 381 }
377 this._forceCompositingModeCheckbox.checked = compositing; 382 this._forceCompositingModeCheckbox.checked = compositing;
378 }, 383 },
379 384
380 /** 385 /**
386 * @param {WebInspector.Event=} event
387 */
388 _cssSourceMapsEnablementChanged: function(event)
389 {
390 var cssSourceMapsEnabled = event ? /** @type {boolean} */ (event.data) : WebInspector.settings.cssSourceMapsEnabled.get();
391 this._cssSourceMapSettings.disabled = !cssSourceMapsEnabled;
392 },
393
394 /**
381 * @param {HTMLFieldSetElement} fieldset 395 * @param {HTMLFieldSetElement} fieldset
382 */ 396 */
383 _timelineLimitStackFramesChanged: function(fieldset) 397 _timelineLimitStackFramesChanged: function(fieldset)
384 { 398 {
385 fieldset.disabled = !WebInspector.settings.timelineLimitStackFramesFlag. get(); 399 fieldset.disabled = !WebInspector.settings.timelineLimitStackFramesFlag. get();
386 }, 400 },
387 401
388 _updateScriptDisabledCheckbox: function() 402 _updateScriptDisabledCheckbox: function()
389 { 403 {
390 function executionStatusCallback(error, status) 404 function executionStatusCallback(error, status)
(...skipping 1064 matching lines...) Expand 10 before | Expand all | Expand 10 after
1455 var columns = this.columns(); 1469 var columns = this.columns();
1456 for (var i = 0; i < columns.length; ++i) { 1470 for (var i = 0; i < columns.length; ++i) {
1457 var columnId = columns[i]; 1471 var columnId = columns[i];
1458 var inputElement = this._addInputElements[columnId]; 1472 var inputElement = this._addInputElements[columnId];
1459 inputElement.value = ""; 1473 inputElement.value = "";
1460 } 1474 }
1461 }, 1475 },
1462 1476
1463 __proto__: WebInspector.SettingsList.prototype 1477 __proto__: WebInspector.SettingsList.prototype
1464 } 1478 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/Settings.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698