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

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

Issue 2266473003: [Devtools] [Regression fix] Network Requests with data urls (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: [Devtools] [Regression fix] Network Requests with data urls 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/network/request-name-path-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 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 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 552 matching lines...) Expand 10 before | Expand all | Expand 10 after
563 { 563 {
564 if (this._parsedURL.isDataURL()) { 564 if (this._parsedURL.isDataURL()) {
565 this._name = this._parsedURL.dataURLDisplayName(); 565 this._name = this._parsedURL.dataURLDisplayName();
566 this._path = ""; 566 this._path = "";
567 } else if (this._parsedURL.isAboutBlank()) { 567 } else if (this._parsedURL.isAboutBlank()) {
568 this._name = this._parsedURL.url; 568 this._name = this._parsedURL.url;
569 this._path = ""; 569 this._path = "";
570 } else { 570 } else {
571 this._path = this._parsedURL.host + this._parsedURL.folderPathCompon ents; 571 this._path = this._parsedURL.host + this._parsedURL.folderPathCompon ents;
572 572
573 this._path = this._path.trimURL(this.target().inspectedURL().asParse dURL().host); 573 var inspectedURL = this.target().inspectedURL().asParsedURL();
574 this._path = this._path.trimURL(inspectedURL ? inspectedURL.host : " ");
574 if (this._parsedURL.lastPathComponent || this._parsedURL.queryParams ) 575 if (this._parsedURL.lastPathComponent || this._parsedURL.queryParams )
575 this._name = this._parsedURL.lastPathComponent + (this._parsedUR L.queryParams ? "?" + this._parsedURL.queryParams : ""); 576 this._name = this._parsedURL.lastPathComponent + (this._parsedUR L.queryParams ? "?" + this._parsedURL.queryParams : "");
576 else if (this._parsedURL.folderPathComponents) { 577 else if (this._parsedURL.folderPathComponents) {
577 this._name = this._parsedURL.folderPathComponents.substring(this ._parsedURL.folderPathComponents.lastIndexOf("/") + 1) + "/"; 578 this._name = this._parsedURL.folderPathComponents.substring(this ._parsedURL.folderPathComponents.lastIndexOf("/") + 1) + "/";
578 this._path = this._path.substring(0, this._path.lastIndexOf("/") ); 579 this._path = this._path.substring(0, this._path.lastIndexOf("/") );
579 } else { 580 } else {
580 this._name = this._parsedURL.host; 581 this._name = this._parsedURL.host;
581 this._path = ""; 582 this._path = "";
582 } 583 }
583 } 584 }
(...skipping 656 matching lines...) Expand 10 before | Expand all | Expand 10 after
1240 /** 1241 /**
1241 * @return {!WebInspector.NetworkManager} 1242 * @return {!WebInspector.NetworkManager}
1242 */ 1243 */
1243 networkManager: function() 1244 networkManager: function()
1244 { 1245 {
1245 return this._networkManager; 1246 return this._networkManager;
1246 }, 1247 },
1247 1248
1248 __proto__: WebInspector.SDKObject.prototype 1249 __proto__: WebInspector.SDKObject.prototype
1249 } 1250 }
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/inspector/network/request-name-path-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698