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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/audits2/Audits2Panel.js

Issue 2440953003: DevTools: use semicolons after each statement. (Closed)
Patch Set: rebaseline Created 4 years, 1 month 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 /** 5 /**
6 * @constructor 6 * @constructor
7 * @extends {WebInspector.Panel} 7 * @extends {WebInspector.Panel}
8 */ 8 */
9 WebInspector.Audits2Panel = function() 9 WebInspector.Audits2Panel = function()
10 { 10 {
11 WebInspector.Panel.call(this, "audits2"); 11 WebInspector.Panel.call(this, "audits2");
12 this.contentElement.classList.add("vbox"); 12 this.contentElement.classList.add("vbox");
13 this.contentElement.appendChild(createTextButton(WebInspector.UIString("Star t"), this._start.bind(this))); 13 this.contentElement.appendChild(createTextButton(WebInspector.UIString("Star t"), this._start.bind(this)));
14 this.contentElement.appendChild(createTextButton(WebInspector.UIString("Stop "), this._stop.bind(this))); 14 this.contentElement.appendChild(createTextButton(WebInspector.UIString("Stop "), this._stop.bind(this)));
15 } 15 };
16 16
17 WebInspector.Audits2Panel.prototype = { 17 WebInspector.Audits2Panel.prototype = {
18 _start: function() 18 _start: function()
19 { 19 {
20 WebInspector.targetManager.interceptMainConnection(this._dispatchProtoco lMessage.bind(this)).then(rawConnection => { 20 WebInspector.targetManager.interceptMainConnection(this._dispatchProtoco lMessage.bind(this)).then(rawConnection => {
21 this._rawConnection = rawConnection; 21 this._rawConnection = rawConnection;
22 this._send("start"); 22 this._send("start");
23 }); 23 });
24 }, 24 },
25 25
(...skipping 25 matching lines...) Expand all
51 if (!this._backendPromise) { 51 if (!this._backendPromise) {
52 this._backendPromise = WebInspector.serviceManager.createAppService( "audits2_worker", "Audits2Service", false).then(backend => { 52 this._backendPromise = WebInspector.serviceManager.createAppService( "audits2_worker", "Audits2Service", false).then(backend => {
53 this._backend = backend; 53 this._backend = backend;
54 this._backend.on("sendProtocolMessage", result => this._rawConne ction.send(result.message)); 54 this._backend.on("sendProtocolMessage", result => this._rawConne ction.send(result.message));
55 }); 55 });
56 } 56 }
57 return this._backendPromise.then(() => this._backend ? this._backend.sen d(method, params) : undefined); 57 return this._backendPromise.then(() => this._backend ? this._backend.sen d(method, params) : undefined);
58 }, 58 },
59 59
60 __proto__: WebInspector.Panel.prototype 60 __proto__: WebInspector.Panel.prototype
61 } 61 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698