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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/security/SecurityPanel.js

Issue 2211413005: DevTools security panel: refresh explanations when clearing origins (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: undo accidental change Created 4 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
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-expected.txt ('k') | 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 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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.PanelWithSidebar} 7 * @extends {WebInspector.PanelWithSidebar}
8 * @implements {WebInspector.TargetManager.Observer} 8 * @implements {WebInspector.TargetManager.Observer}
9 */ 9 */
10 WebInspector.SecurityPanel = function() 10 WebInspector.SecurityPanel = function()
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 }, 260 },
261 261
262 /** 262 /**
263 * @override 263 * @override
264 * @param {!WebInspector.Target} target 264 * @param {!WebInspector.Target} target
265 */ 265 */
266 targetRemoved: function(target) 266 targetRemoved: function(target)
267 { 267 {
268 }, 268 },
269 269
270 _clearOrigins: function() 270 _clearOrigins: function()
dgozman 2016/08/08 15:42:13 Can we inline this function into _onMainFrameNavig
estark 2016/08/08 16:53:05 Done.
271 { 271 {
272 this.selectAndSwitchToMainView(); 272 this.selectAndSwitchToMainView();
273 this._sidebarTree.clearOrigins(); 273 this._sidebarTree.clearOrigins();
274 this._origins.clear(); 274 this._origins.clear();
275 this._lastResponseReceivedForLoaderId.clear(); 275 this._lastResponseReceivedForLoaderId.clear();
276 this._filterRequestCounts.clear(); 276 this._filterRequestCounts.clear();
277 // After clearing the filtered request counts, refresh the
278 // explanations to reflect the new counts.
279 this._mainView.refreshExplanations();
277 }, 280 },
278 281
279 /** 282 /**
280 * @param {!WebInspector.Event} event 283 * @param {!WebInspector.Event} event
281 */ 284 */
282 _onMainFrameNavigated: function(event) { 285 _onMainFrameNavigated: function(event) {
dgozman 2016/08/08 15:42:13 style: and put { on next line?
estark 2016/08/08 16:53:05 Done.
283 286
284 var frame = /** type {!PageAgent.Frame}*/ (event.data); 287 var frame = /** type {!PageAgent.Frame}*/ (event.data);
285 var request = this._lastResponseReceivedForLoaderId.get(frame.loaderId); 288 var request = this._lastResponseReceivedForLoaderId.get(frame.loaderId);
286 this._clearOrigins(); 289 this._clearOrigins();
287 290
288 291
289 if (request) { 292 if (request) {
290 var origin = WebInspector.ParsedURL.extractOrigin(request.url); 293 var origin = WebInspector.ParsedURL.extractOrigin(request.url);
291 this._sidebarTree.setMainOrigin(origin); 294 this._sidebarTree.setMainOrigin(origin);
292 this._processRequest(request); 295 this._processRequest(request);
(...skipping 668 matching lines...) Expand 10 before | Expand all | Expand 10 after
961 row.createChild("div").textContent = key; 964 row.createChild("div").textContent = key;
962 965
963 var valueDiv = row.createChild("div"); 966 var valueDiv = row.createChild("div");
964 if (typeof value === "string") { 967 if (typeof value === "string") {
965 valueDiv.textContent = value; 968 valueDiv.textContent = value;
966 } else { 969 } else {
967 valueDiv.appendChild(value); 970 valueDiv.appendChild(value);
968 } 971 }
969 } 972 }
970 } 973 }
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698