Bug 87424 - Web Inspector: Resource object has no methods getContent and setContent
Summary: Web Inspector: Resource object has no methods getContent and setContent
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Jan Keromnes
URL: http://code.google.com/chrome/extensi...
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-24 13:46 PDT by Jan Keromnes
Modified: 2012-05-25 01:31 PDT (History)
13 users (show)

See Also:


Attachments
Patch (3.27 KB, patch)
2012-05-24 15:54 PDT, Jan Keromnes
vsevik: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Keromnes 2012-05-24 13:46:30 PDT
DOCUMENTATION:
- http://code.google.com/chrome/extensions/devtools.panels.html#method-setOpenResourceHandler
- http://code.google.com/chrome/extensions/devtools.inspectedWindow.html#type-Resource

STEPS TO REPRODUCE:
- Write a devtools extension using `chrome.devtools.panels.setOpenResourceHandler(function callback)`.
- The handler callback `function(object Resource) {...};` receives a `Resource` object whenever the user clicks on a resource link.

EVENT: User clicks on a valid resource link.

EXPECTED: Handler called with `Resource` object, having attributes `type` and `url`, and methods `getContent` and `setContent`.

OBSERVED: Handler called with `Resource` object, having attributes `type` and `url, but no methods.
Comment 1 Jan Keromnes 2012-05-24 13:47:49 PDT
I am writing a patch to fix this, and a test to assert correct behavior.
Comment 2 Jan Keromnes 2012-05-24 15:54:37 PDT
Created attachment 143911 [details]
Patch
Comment 3 Andrey Kosyakov 2012-05-25 00:34:16 PDT
Comment on attachment 143911 [details]
Patch

LGTM. Thanks for fixing this and welcome to WebKit!
Comment 4 Andrey Kosyakov 2012-05-25 00:35:22 PDT
Vsevolod, could you please stamp this.
Comment 5 Andrey Kosyakov 2012-05-25 01:10:23 PDT
Committed r118492: <http://trac.webkit.org/changeset/118492>
Comment 6 Jan Keromnes 2012-05-25 01:23:11 PDT
Thanks Andrey!