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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/resources/AppManifestView.js

Issue 2851913002: [DevTools] Do not expose agents on Target
Patch Set: storage and tests.js Created 3 years, 7 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
OLDNEW
1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 * @implements {SDK.SDKModelObserver<!SDK.ResourceTreeModel>} 5 * @implements {SDK.SDKModelObserver<!SDK.ResourceTreeModel>}
6 * @unrestricted 6 * @unrestricted
7 */ 7 */
8 Resources.AppManifestView = class extends UI.VBox { 8 Resources.AppManifestView = class extends UI.VBox {
9 constructor() { 9 constructor() {
10 super(true); 10 super(true);
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 if (typeof value !== 'string') 150 if (typeof value !== 'string')
151 return ''; 151 return '';
152 return value; 152 return value;
153 } 153 }
154 } 154 }
155 155
156 /** 156 /**
157 * @param {!Common.Event} event 157 * @param {!Common.Event} event
158 */ 158 */
159 _addToHomescreen(event) { 159 _addToHomescreen(event) {
160 var target = SDK.targetManager.mainTarget(); 160 var resourceTreeModel = SDK.targetManager.models(SDK.ResourceTreeModel)[0];
161 if (target && target.hasBrowserCapability()) { 161 if (resourceTreeModel) {
162 target.pageAgent().requestAppBanner(); 162 resourceTreeModel.requestAppBanner();
163 Common.console.show(); 163 Common.console.show();
164 } 164 }
165 } 165 }
166 }; 166 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698