| Summary: | Implement ServiceWorker WindowClient.ancestorOrigins | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | youenn fablet <youennf> | ||||||||||||||
| Component: | Service Workers | Assignee: | youenn fablet <youennf> | ||||||||||||||
| Status: | RESOLVED FIXED | ||||||||||||||||
| Severity: | Normal | CC: | achristensen, beidson, benjamin, cdumez, changseok, clopez, cmarcelo, esprehn+autocc, ews-watchlist, fred.wang, glenn, kondapallykalyan, nham, pdr, rbuis, simon.fraser, webkit-bug-importer | ||||||||||||||
| Priority: | P2 | Keywords: | InRadar | ||||||||||||||
| Version: | WebKit Nightly Build | ||||||||||||||||
| Hardware: | Unspecified | ||||||||||||||||
| OS: | Unspecified | ||||||||||||||||
| Attachments: |
|
||||||||||||||||
|
Description
youenn fablet
2022-03-28 02:06:50 PDT
Created attachment 455895 [details]
Patch
Created attachment 455910 [details]
Patch
Created attachment 455913 [details]
Patch
Comment on attachment 455913 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=455913&action=review r=me but watch out before landing because I think I found a correctness bug. > Source/WebCore/workers/service/ServiceWorkerClientData.cpp:62 > + return { identifier, type, frameType, url.isolatedCopy(), lastNavigationWasAppInitiated, isVisible, isFocused, focusOrder, ancestorOrigins }; I bet this should be `crossThreadCopy(ancestorOrigins)`, not `ancestorOrigins`. > Source/WebCore/workers/service/ServiceWorkerClientData.cpp:80 > + while (frame) { nit: I personally think this would look nicer as a for loop (see how it is already implemented in Location::ancestorOrigins()). > Source/WebCore/workers/service/ServiceWorkerWindowClient.h:46 > + bool focused() const { return data().isFocused; } Not a fan of this change as it seems to go against coding style. Booleans without prefixes don't look great. (In reply to Chris Dumez from comment #4) > Comment on attachment 455913 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=455913&action=review > > r=me but watch out before landing because I think I found a correctness bug. Thanks, will fix it. Created attachment 456108 [details]
Patch for landing
Committed r292105 (249025@main): <https://commits.webkit.org/249025@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 456108 [details]. Reopening to attach new patch. Created attachment 456140 [details]
Patch
This patch modifies the imported WPT tests. Please ensure that any changes on the tests (not coming from a WPT import) are exported to WPT. Please see https://trac.webkit.org/wiki/WPTExportProcess Created attachment 456142 [details]
Patch
Uploaded to wrong bug. |