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

Unified Diff: Source/devtools/front_end/main/AdvancedApp.js

Issue 340723005: [DevTools] Remove unnecessary emulation checkboxes and simplify UX. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 6 years, 6 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
« no previous file with comments | « Source/devtools/front_end/elements/OverridesView.js ('k') | Source/devtools/front_end/main/Main.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/main/AdvancedApp.js
diff --git a/Source/devtools/front_end/main/AdvancedApp.js b/Source/devtools/front_end/main/AdvancedApp.js
index 9cd4af07b8d8f34c4829e8d7f075a57d5b158a15..fbbb440d61d19e28454234d68d1f9be796540b79 100644
--- a/Source/devtools/front_end/main/AdvancedApp.js
+++ b/Source/devtools/front_end/main/AdvancedApp.js
@@ -14,21 +14,21 @@ WebInspector.AdvancedApp = function()
if (!WebInspector.experimentsSettings.responsiveDesign.isEnabled())
return;
- this._toggleResponsiveDesignButton = new WebInspector.StatusBarButton(WebInspector.UIString("Responsive design and mobile emulation."), "responsive-design-status-bar-item");
- this._toggleResponsiveDesignButton.toggled = WebInspector.settings.responsiveDesignEnabled.get();
- this._toggleResponsiveDesignButton.addEventListener("click", this._toggleResponsiveDesign, this);
- WebInspector.settings.responsiveDesignEnabled.addChangeListener(this._responsiveDesignEnabledChanged, this);
+ this._toggleEmulationButton = new WebInspector.StatusBarButton(WebInspector.UIString("Responsive design and mobile emulation."), "responsive-design-status-bar-item");
+ this._toggleEmulationButton.toggled = WebInspector.overridesSupport.settings.emulationEnabled.get();
+ this._toggleEmulationButton.addEventListener("click", this._toggleEmulationEnabled, this);
+ WebInspector.overridesSupport.settings.emulationEnabled.addChangeListener(this._emulationEnabledChanged, this);
};
WebInspector.AdvancedApp.prototype = {
- _toggleResponsiveDesign: function()
+ _toggleEmulationEnabled: function()
{
- WebInspector.settings.responsiveDesignEnabled.set(!this._toggleResponsiveDesignButton.toggled);
+ WebInspector.overridesSupport.settings.emulationEnabled.set(!this._toggleEmulationButton.toggled);
},
- _responsiveDesignEnabledChanged: function()
+ _emulationEnabledChanged: function()
{
- this._toggleResponsiveDesignButton.toggled = WebInspector.settings.responsiveDesignEnabled.get();
+ this._toggleEmulationButton.toggled = WebInspector.overridesSupport.settings.emulationEnabled.get();
},
createRootView: function()
@@ -192,7 +192,7 @@ WebInspector.AdvancedApp.ResponsiveDesignButtonProvider.prototype = {
{
if (!(WebInspector.app instanceof WebInspector.AdvancedApp))
return null;
- return /** @type {!WebInspector.AdvancedApp} */ (WebInspector.app)._toggleResponsiveDesignButton || null;
+ return /** @type {!WebInspector.AdvancedApp} */ (WebInspector.app)._toggleEmulationButton || null;
}
}
« no previous file with comments | « Source/devtools/front_end/elements/OverridesView.js ('k') | Source/devtools/front_end/main/Main.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698