OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @constructor | 6 * @constructor |
7 * @extends {WebInspector.App} | 7 * @extends {WebInspector.App} |
8 */ | 8 */ |
9 WebInspector.AdvancedApp = function() | 9 WebInspector.AdvancedApp = function() |
10 { | 10 { |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 * @param {!WebInspector.Event} event | 79 * @param {!WebInspector.Event} event |
80 */ | 80 */ |
81 _openToolboxWindow: function(event) | 81 _openToolboxWindow: function(event) |
82 { | 82 { |
83 if (/** @type {string} */ (event.data.to) !== WebInspector.DockControlle
r.State.Undocked) | 83 if (/** @type {string} */ (event.data.to) !== WebInspector.DockControlle
r.State.Undocked) |
84 return; | 84 return; |
85 | 85 |
86 if (this._toolboxWindow) | 86 if (this._toolboxWindow) |
87 return; | 87 return; |
88 | 88 |
89 var url = window.location.href.replace("devtools.html", "toolbox.html"); | 89 var url = window.location.href.replace("inspector.html", "toolbox.html")
; |
90 this._toolboxWindow = window.open(url, undefined); | 90 this._toolboxWindow = window.open(url, undefined); |
91 }, | 91 }, |
92 | 92 |
93 /** | 93 /** |
94 * @param {!Document} toolboxDocument | 94 * @param {!Document} toolboxDocument |
95 */ | 95 */ |
96 toolboxLoaded: function(toolboxDocument) | 96 toolboxLoaded: function(toolboxDocument) |
97 { | 97 { |
98 WebInspector.initializeUIUtils(toolboxDocument.defaultView); | 98 WebInspector.initializeUIUtils(toolboxDocument.defaultView); |
99 WebInspector.installComponentRootStyles(/** @type {!Element} */ (toolbox
Document.body)); | 99 WebInspector.installComponentRootStyles(/** @type {!Element} */ (toolbox
Document.body)); |
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
293 handleAction: function() | 293 handleAction: function() |
294 { | 294 { |
295 if (!WebInspector.overridesSupport.responsiveDesignAvailable()) | 295 if (!WebInspector.overridesSupport.responsiveDesignAvailable()) |
296 return false; | 296 return false; |
297 if (!(WebInspector.app instanceof WebInspector.AdvancedApp)) | 297 if (!(WebInspector.app instanceof WebInspector.AdvancedApp)) |
298 return false; | 298 return false; |
299 WebInspector.app._toggleEmulationEnabled(); | 299 WebInspector.app._toggleEmulationEnabled(); |
300 return true; | 300 return true; |
301 } | 301 } |
302 } | 302 } |
OLD | NEW |