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

Unified Diff: Source/WebCore/inspector/front-end/ResourcesPanel.js

Issue 7648029: Merge 92835 - Web Inspector: [REGRESSION] Resources panel search fails when search result is foun... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/835/
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/inspector/front-end/ResourcesPanel.js
===================================================================
--- Source/WebCore/inspector/front-end/ResourcesPanel.js (revision 93035)
+++ Source/WebCore/inspector/front-end/ResourcesPanel.js (working copy)
@@ -726,6 +726,12 @@
continue;
var resource = frameTreeElement.resourceByURL(searchResult.url);
+ // FIXME: When the same script is used in several frames and this script contains at least
+ // one search result then some search results can not be matched with a resource on panel.
+ // https://bugs.webkit.org/show_bug.cgi?id=66005
+ if (!resource)
+ continue;
+
if (resource.history.length > 0)
continue; // Skip edited resources.
this._findTreeElementForResource(resource).searchMatchesFound(searchResult.matchesCount);
@@ -1130,7 +1136,8 @@
resourceByURL: function(url)
{
- return this._treeElementForResource[url].representedObject;
+ var treeElement = this._treeElementForResource[url];
+ return treeElement ? treeElement.representedObject : null;
},
appendChild: function(treeElement)
« 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