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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/sdk/NetworkManager.js

Issue 2691433006: [Devtools] Persist network request blocking (Closed)
Patch Set: Merge Created 3 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 } 677 }
678 }; 678 };
679 679
680 /** 680 /**
681 * @implements {SDK.TargetManager.Observer} 681 * @implements {SDK.TargetManager.Observer}
682 * @unrestricted 682 * @unrestricted
683 */ 683 */
684 SDK.MultitargetNetworkManager = class extends Common.Object { 684 SDK.MultitargetNetworkManager = class extends Common.Object {
685 constructor() { 685 constructor() {
686 super(); 686 super();
687
688 this._userAgentOverride = '';
689 this._isRequestBlockingEnabled = false;
690 /** @type {!Set<!Protocol.NetworkAgent>} */ 687 /** @type {!Set<!Protocol.NetworkAgent>} */
691 this._agents = new Set(); 688 this._agents = new Set();
689
690 this._isRequestBlockingEnabled = false;
691 this._userAgentOverride = '';
692 /** @type {!SDK.NetworkManager.Conditions} */ 692 /** @type {!SDK.NetworkManager.Conditions} */
693 this._networkConditions = SDK.NetworkManager.NoThrottlingConditions; 693 this._networkConditions = SDK.NetworkManager.NoThrottlingConditions;
694 694
695 this._blockedSetting = Common.moduleSetting('networkBlockedURLs'); 695 this._blockedSetting = Common.moduleSetting('networkBlockedURLs');
696 this._blockedSetting.addChangeListener(this._updateBlockedURLs, this); 696 this._blockedSetting.addChangeListener(this._updateBlockedURLs, this);
697 this._blockedSetting.set([]); 697 this._blockedSetting.set([]);
698 this._updateBlockedURLs(); 698 this._updateBlockedURLs();
699 699
700 SDK.targetManager.observeTargets(this, SDK.Target.Capability.Network); 700 SDK.targetManager.observeTargets(this, SDK.Target.Capability.Network);
701 } 701 }
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
908 UserAgentChanged: Symbol('UserAgentChanged') 908 UserAgentChanged: Symbol('UserAgentChanged')
909 }; 909 };
910 910
911 /** @implements {Common.Emittable} */ 911 /** @implements {Common.Emittable} */
912 SDK.MultitargetNetworkManager.RequestBlockingEnabledChangedEvent = class {}; 912 SDK.MultitargetNetworkManager.RequestBlockingEnabledChangedEvent = class {};
913 913
914 /** 914 /**
915 * @type {!SDK.MultitargetNetworkManager} 915 * @type {!SDK.MultitargetNetworkManager}
916 */ 916 */
917 SDK.multitargetNetworkManager; 917 SDK.multitargetNetworkManager;
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698