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

Unified Diff: Source/devtools/front_end/emulation/OverridesUI.js

Issue 1200903003: [DevTools] Pass screen size and position to setDeviceMetricsOverrides. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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
Index: Source/devtools/front_end/emulation/OverridesUI.js
diff --git a/Source/devtools/front_end/emulation/OverridesUI.js b/Source/devtools/front_end/emulation/OverridesUI.js
index 51570b6aece534fab442231a8502c33e7d298dea..668d1b9bdb01834ce365628e7cb366efe8f76521 100644
--- a/Source/devtools/front_end/emulation/OverridesUI.js
+++ b/Source/devtools/front_end/emulation/OverridesUI.js
@@ -7,10 +7,11 @@ WebInspector.OverridesUI = {}
/**
* @constructor
* @param {!Element} rotateButton
+ * @param {?function(!WebInspector.EmulatedDevice, !WebInspector.EmulatedDevice.Mode)} callback
*/
-WebInspector.DeviceSelect = function(rotateButton)
+WebInspector.DeviceSelect = function(rotateButton, callback)
{
- this._callback = null;
+ this._callback = callback;
this._rotateButton = rotateButton;
this.element = createElement("p");
@@ -45,14 +46,6 @@ WebInspector.DeviceSelect = function(rotateButton)
}
WebInspector.DeviceSelect.prototype = {
- /**
- * @param {function(!WebInspector.EmulatedDevice, !WebInspector.EmulatedDevice.Mode)=} callback
- */
- setCallback: function(callback)
- {
- this._callback = callback;
- },
-
_deviceListChanged: function()
{
this._deviceSelectElement.removeChildren();
« no previous file with comments | « Source/devtools/front_end/emulation/OverridesSupport.js ('k') | Source/devtools/front_end/emulation/OverridesView.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698