| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 * @extends {WebInspector.VBox} | 6 * @extends {WebInspector.VBox} |
| 7 * @param {!WebInspector.InspectedPagePlaceholder} inspectedPagePlaceholder | 7 * @param {!WebInspector.InspectedPagePlaceholder} inspectedPagePlaceholder |
| 8 * @constructor | 8 * @constructor |
| 9 */ | 9 */ |
| 10 WebInspector.DeviceModeWrapper = function(inspectedPagePlaceholder) | 10 WebInspector.DeviceModeWrapper = function(inspectedPagePlaceholder) |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 * @param {string} actionId | 73 * @param {string} actionId |
| 74 * @return {boolean} | 74 * @return {boolean} |
| 75 */ | 75 */ |
| 76 handleAction: function(context, actionId) | 76 handleAction: function(context, actionId) |
| 77 { | 77 { |
| 78 if (WebInspector.DeviceModeView._wrapperInstance) { | 78 if (WebInspector.DeviceModeView._wrapperInstance) { |
| 79 if (actionId === "emulation.toggle-device-mode") { | 79 if (actionId === "emulation.toggle-device-mode") { |
| 80 WebInspector.DeviceModeView._wrapperInstance._toggleDeviceMode()
; | 80 WebInspector.DeviceModeView._wrapperInstance._toggleDeviceMode()
; |
| 81 return true; | 81 return true; |
| 82 } | 82 } |
| 83 if (actionId === "emulation.request-app-banner") { | |
| 84 var target = WebInspector.targetManager.mainTarget(); | |
| 85 if (target && target.isPage()) | |
| 86 target.pageAgent().requestAppBanner(); | |
| 87 return true; | |
| 88 } | |
| 89 } | 83 } |
| 90 return false; | 84 return false; |
| 91 } | 85 } |
| 92 } | 86 } |
| OLD | NEW |