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

Side by Side Diff: chrome/browser/resources/net_internals/spdy_view.js

Issue 7564029: Use javascript strict mode throughout a number of net-internals files. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix one more var Created 9 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 * This view displays a summary of the state of each SPDY sessions, and 6 * This view displays a summary of the state of each SPDY sessions, and
7 * has links to display them in the events tab. 7 * has links to display them in the events tab.
8 */ 8 */
9 var SpdyView = (function() {
10 'use strict';
9 11
10 var SpdyView = (function() {
11 // IDs for special HTML elements in spdy_view.html 12 // IDs for special HTML elements in spdy_view.html
12 const MAIN_BOX_ID = 'spdy-view-tab-content'; 13 var MAIN_BOX_ID = 'spdy-view-tab-content';
13 const ENABLED_SPAN_ID = 'spdy-view-enabled-span'; 14 var ENABLED_SPAN_ID = 'spdy-view-enabled-span';
14 const USE_ALTERNATE_PROTOCOL_SPAN_ID = 'spdy-view-alternate-protocol-span'; 15 var USE_ALTERNATE_PROTOCOL_SPAN_ID = 'spdy-view-alternate-protocol-span';
15 const FORCE_ALWAYS_SPAN_ID = 'spdy-view-force-always-span'; 16 var FORCE_ALWAYS_SPAN_ID = 'spdy-view-force-always-span';
16 const FORCE_OVER_SSL_SPAN_ID = 'spdy-view-force-over-ssl-span'; 17 var FORCE_OVER_SSL_SPAN_ID = 'spdy-view-force-over-ssl-span';
17 const NEXT_PROTOCOLS_SPAN_ID = 'spdy-view-next-protocols-span'; 18 var NEXT_PROTOCOLS_SPAN_ID = 'spdy-view-next-protocols-span';
18 const ALTERNATE_PROTOCOL_MAPPINGS_DIV_ID = 19 var ALTERNATE_PROTOCOL_MAPPINGS_DIV_ID =
19 'spdy-view-alternate-protocol-mappings-div'; 20 'spdy-view-alternate-protocol-mappings-div';
20 const SESSION_NONE_SPAN_ID = 'spdy-view-session-none-span'; 21 var SESSION_NONE_SPAN_ID = 'spdy-view-session-none-span';
21 const SESSION_LINK_SPAN_ID = 'spdy-view-session-link-span'; 22 var SESSION_LINK_SPAN_ID = 'spdy-view-session-link-span';
22 const SESSION_DIV_ID = 'spdy-view-session-div'; 23 var SESSION_DIV_ID = 'spdy-view-session-div';
23 24
24 // We inherit from DivView. 25 // We inherit from DivView.
25 var superClass = DivView; 26 var superClass = DivView;
26 27
27 /** 28 /**
28 * @constructor 29 * @constructor
29 */ 30 */
30 function SpdyView() { 31 function SpdyView() {
32 assertFirstConstructorCall(SpdyView);
33
31 // Call superclass's constructor. 34 // Call superclass's constructor.
32 superClass.call(this, MAIN_BOX_ID); 35 superClass.call(this, MAIN_BOX_ID);
33 36
34 g_browser.addSpdySessionInfoObserver(this); 37 g_browser.addSpdySessionInfoObserver(this);
35 g_browser.addSpdyStatusObserver(this); 38 g_browser.addSpdyStatusObserver(this);
36 g_browser.addSpdyAlternateProtocolMappingsObserver(this); 39 g_browser.addSpdyAlternateProtocolMappingsObserver(this);
37 40
38 this.spdyEnabledSpan_ = $(ENABLED_SPAN_ID); 41 this.spdyEnabledSpan_ = $(ENABLED_SPAN_ID);
39 this.spdyUseAlternateProtocolSpan_ = $(USE_ALTERNATE_PROTOCOL_SPAN_ID); 42 this.spdyUseAlternateProtocolSpan_ = $(USE_ALTERNATE_PROTOCOL_SPAN_ID);
40 this.spdyForceAlwaysSpan_ = $(FORCE_ALWAYS_SPAN_ID); 43 this.spdyForceAlwaysSpan_ = $(FORCE_ALWAYS_SPAN_ID);
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 tablePrinter.addRow(); 188 tablePrinter.addRow();
186 189
187 tablePrinter.addCell(entry.host_port_pair); 190 tablePrinter.addCell(entry.host_port_pair);
188 tablePrinter.addCell(entry.alternate_protocol); 191 tablePrinter.addCell(entry.alternate_protocol);
189 } 192 }
190 return tablePrinter; 193 return tablePrinter;
191 } 194 }
192 195
193 return SpdyView; 196 return SpdyView;
194 })(); 197 })();
OLDNEW
« no previous file with comments | « chrome/browser/resources/net_internals/sockets_view.js ('k') | chrome/browser/resources/net_internals/test_view.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698