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

Side by Side Diff: chrome/browser/resources/net_internals/http_cache_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 information on the HTTP cache. 6 * This view displays information on the HTTP cache.
7 */ 7 */
8 var HttpCacheView = (function() {
9 'use strict';
8 10
9 var HttpCacheView = (function() {
10 // IDs for special HTML elements in http_cache_view.html 11 // IDs for special HTML elements in http_cache_view.html
11 const MAIN_BOX_ID = 'http-cache-view-tab-content'; 12 var MAIN_BOX_ID = 'http-cache-view-tab-content';
12 const STATS_DIV_ID = 'http-cache-view-cache-stats'; 13 var STATS_DIV_ID = 'http-cache-view-cache-stats';
13 14
14 // We inherit from DivView. 15 // We inherit from DivView.
15 var superClass = DivView; 16 var superClass = DivView;
16 17
17 /** 18 /**
18 * @constructor 19 * @constructor
19 */ 20 */
20 function HttpCacheView() { 21 function HttpCacheView() {
22 assertFirstConstructorCall(HttpCacheView);
23
21 // Call superclass's constructor. 24 // Call superclass's constructor.
22 superClass.call(this, MAIN_BOX_ID); 25 superClass.call(this, MAIN_BOX_ID);
23 26
24 this.statsDiv_ = $(STATS_DIV_ID); 27 this.statsDiv_ = $(STATS_DIV_ID);
25 28
26 // Register to receive http cache info. 29 // Register to receive http cache info.
27 g_browser.addHttpCacheInfoObserver(this); 30 g_browser.addHttpCacheInfoObserver(this);
28 } 31 }
29 32
30 cr.addSingletonGetter(HttpCacheView); 33 cr.addSingletonGetter(HttpCacheView);
(...skipping 17 matching lines...) Expand all
48 for (var statName in info.stats) { 51 for (var statName in info.stats) {
49 var li = addNode(statsUl, 'li'); 52 var li = addNode(statsUl, 'li');
50 addTextNode(li, statName + ': ' + info.stats[statName]); 53 addTextNode(li, statName + ': ' + info.stats[statName]);
51 } 54 }
52 return true; 55 return true;
53 } 56 }
54 }; 57 };
55 58
56 return HttpCacheView; 59 return HttpCacheView;
57 })(); 60 })();
OLDNEW
« no previous file with comments | « chrome/browser/resources/net_internals/hsts_view.js ('k') | chrome/browser/resources/net_internals/http_throttling_view.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698