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

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

Issue 7531005: Rename the net_internals file names to include hyphens. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Add some missing files 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
(Empty)
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
3 // found in the LICENSE file.
4
5 /**
6 * This view displays information related to HTTP throttling.
7 * @constructor
8 */
9 function HttpThrottlingView() {
10 const mainBoxId = 'httpThrottlingTabContent';
11 const enableCheckboxId = 'enableHttpThrottlingCheckbox';
12
13 DivView.call(this, mainBoxId);
14
15 this.enableCheckbox_ = $(enableCheckboxId);
16 this.enableCheckbox_.onclick = this.onEnableCheckboxClicked_.bind(this);
17
18 g_browser.addHttpThrottlingObserver(this);
19 }
20
21 inherits(HttpThrottlingView, DivView);
22
23 /**
24 * Gets informed that HTTP throttling has been enabled/disabled.
25 * @param {boolean} enabled HTTP throttling has been enabled.
26 */
27 HttpThrottlingView.prototype.onHttpThrottlingEnabledPrefChanged = function(
28 enabled) {
29 this.enableCheckbox_.checked = enabled;
30 };
31
32 /**
33 * Handler for the onclick event of the checkbox.
34 */
35 HttpThrottlingView.prototype.onEnableCheckboxClicked_ = function() {
36 g_browser.enableHttpThrottling(this.enableCheckbox_.checked);
37 };
OLDNEW
« no previous file with comments | « chrome/browser/resources/net_internals/httpcacheview.js ('k') | chrome/browser/resources/net_internals/index.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698