Bug 189249 - [Payment Request] PaymentResponse should have an onpayerdetailchange event handler
Summary: [Payment Request] PaymentResponse should have an onpayerdetailchange event ha...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Andy Estes
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-09-03 13:55 PDT by Andy Estes
Modified: 2018-09-04 12:15 PDT (History)
15 users (show)

See Also:


Attachments
Patch (7.81 KB, patch)
2018-09-03 13:57 PDT, Andy Estes
no flags Details | Formatted Diff | Diff
Patch (7.99 KB, patch)
2018-09-04 11:37 PDT, Andy Estes
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andy Estes 2018-09-03 13:55:02 PDT
[Payment Request] PaymentResponse should have an onpayerdetailchange event handler
Comment 1 Andy Estes 2018-09-03 13:57:08 PDT Comment hidden (obsolete)
Comment 2 Alex Christensen 2018-09-04 11:06:02 PDT
Comment on attachment 348790 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=348790&action=review

> Source/WebCore/Modules/paymentrequest/PaymentResponse.cpp:57
> +    return static_cast<ActiveDOMObject&>(m_request.get()).scriptExecutionContext();

You shouldn't need the static cast here.  Just m_request->scriptExecutionContext() ought to work.
Comment 3 Andy Estes 2018-09-04 11:10:09 PDT
Comment on attachment 348790 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=348790&action=review

>> Source/WebCore/Modules/paymentrequest/PaymentResponse.cpp:57
>> +    return static_cast<ActiveDOMObject&>(m_request.get()).scriptExecutionContext();
> 
> You shouldn't need the static cast here.  Just m_request->scriptExecutionContext() ought to work.

Unfortunately not, because PaymentRequest overrides scriptExecutionContext() as a private member function. I guess I could change that to be public, or make PaymentResponse be a ContextDestructionObserver. I'll think about how I want to improve this.

Thanks for reviewing!
Comment 4 WebKit Commit Bot 2018-09-04 11:22:07 PDT Comment hidden (obsolete)
Comment 5 Andy Estes 2018-09-04 11:37:06 PDT
Created attachment 348833 [details]
Patch
Comment 6 WebKit Commit Bot 2018-09-04 12:14:30 PDT
Comment on attachment 348833 [details]
Patch

Clearing flags on attachment: 348833

Committed r235625: <https://trac.webkit.org/changeset/235625>
Comment 7 WebKit Commit Bot 2018-09-04 12:14:32 PDT
All reviewed patches have been landed.  Closing bug.
Comment 8 Radar WebKit Bug Importer 2018-09-04 12:15:21 PDT
<rdar://problem/44107683>