Web Inspector: [Extensions API] provide access to page resources
authorcaseq@chromium.org <caseq@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 23 Aug 2011 15:35:58 +0000 (15:35 +0000)
committercaseq@chromium.org <caseq@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 23 Aug 2011 15:35:58 +0000 (15:35 +0000)
commitfffb46465a82f792e8116bd074ab23e88ca904f3
tree93ffb6d8257c3c5b752e8974add485c6005e27d3
parent63a85014eedc70e4455e8d27b1199f7fc34b71ff
Web Inspector: [Extensions API] provide access to page resources
https://bugs.webkit.org/show_bug.cgi?id=66767

Reviewed by Pavel Feldman.

Source/WebCore:

Test: inspector/extensions/extensions-resources.html

* inspector/front-end/ExtensionAPI.js:
(WebInspector.injectedExtensionAPI.EventSinkImpl.prototype.addListener):
(WebInspector.injectedExtensionAPI):
(WebInspector.injectedExtensionAPI.RequestImpl.prototype.getContent):
(WebInspector.injectedExtensionAPI.InspectedWindow.resourceDispatch):
(WebInspector.injectedExtensionAPI.InspectedWindow.resourceContentDispatch):
(WebInspector.injectedExtensionAPI.InspectedWindow):
(WebInspector.injectedExtensionAPI.InspectedWindow.prototype.eval):
(WebInspector.injectedExtensionAPI.InspectedWindow.prototype.getResources):
(WebInspector.injectedExtensionAPI.InspectedWindow.prototype.getResources.callbackWrapper):
(WebInspector.injectedExtensionAPI.ResourceImpl.prototype.get url):
(WebInspector.injectedExtensionAPI.ResourceImpl.prototype.get type):
(WebInspector.injectedExtensionAPI.ResourceImpl.prototype.getContent):
(WebInspector.injectedExtensionAPI.ResourceImpl.prototype.setContent):
* inspector/front-end/ExtensionServer.js:
(WebInspector.ExtensionServer):
(WebInspector.ExtensionServer.prototype._notifyResourceAdded):
(WebInspector.ExtensionServer.prototype.notifyResourceContentCommitted):
(WebInspector.ExtensionServer.prototype._makeResource):
(WebInspector.ExtensionServer.prototype._onGetPageResources):
(WebInspector.ExtensionServer.prototype._getResourceContent):
(WebInspector.ExtensionServer.prototype._onGetRequestContent):
(WebInspector.ExtensionServer.prototype._onGetResourceContent):
(WebInspector.ExtensionServer.prototype._onSetResourceContent):
(WebInspector.ExtensionServer.prototype.initExtensions):
* inspector/front-end/Resource.js:
(WebInspector.Resource.prototype.addRevision):

LayoutTests:

* http/tests/inspector/resources/extension-main.js:
(trimURL):
* inspector/extensions/extensions-api-expected.txt:
* inspector/extensions/extensions-network-expected.txt:
* inspector/extensions/extensions-network.html:
* inspector/extensions/extensions-resources-expected.txt: Added.
* inspector/extensions/extensions-resources.html: Added.
* inspector/extensions/resources/Ahem.ttf:
* inspector/extensions/resources/test-script.js: Added.
(__test_function):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@93605 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
LayoutTests/ChangeLog
LayoutTests/http/tests/inspector/resources/extension-main.js
LayoutTests/inspector/extensions/extensions-api-expected.txt
LayoutTests/inspector/extensions/extensions-network-expected.txt
LayoutTests/inspector/extensions/extensions-network.html
LayoutTests/inspector/extensions/extensions-resources-expected.txt [new file with mode: 0644]
LayoutTests/inspector/extensions/extensions-resources.html [new file with mode: 0644]
LayoutTests/inspector/extensions/resources/Ahem.ttf [changed mode: 0755->0644]
LayoutTests/inspector/extensions/resources/test-script.js [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/inspector/front-end/ExtensionAPI.js
Source/WebCore/inspector/front-end/ExtensionServer.js
Source/WebCore/inspector/front-end/Resource.js