diff options
Diffstat (limited to 'webkit/glue/devtools/js/devtools.js')
-rw-r--r-- | webkit/glue/devtools/js/devtools.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/webkit/glue/devtools/js/devtools.js b/webkit/glue/devtools/js/devtools.js index 335ee7f..8ae71c9 100644 --- a/webkit/glue/devtools/js/devtools.js +++ b/webkit/glue/devtools/js/devtools.js @@ -410,3 +410,20 @@ WebInspector.ConsoleMessage.prototype.setMessageBody = function(args) { orig.call(this, args); }; })(); + +// Temporary fix for http://crbug/23260. +(function() { +var orig = WebInspector.ResourcesPanel.prototype._createResourceView; +WebInspector.ResourcesPanel.prototype._createResourceView = function( + resource) { + if (resource.type == undefined && resource.url) { + if (resource.url.search('\.js$') != -1) { + resource.type = WebInspector.Resource.Type.Script; + } else if (scriptOrResource.url.search('\.html$') != -1) { + resource.type = WebInspector.Resource.Type.Document; + } + } + + return orig.apply(this, arguments); +}; +})(); |