| Summary: | AX: Conversion of PDFView coordinates to screen coordinates for accessibility should happen on the main thread. | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Andres Gonzalez <andresg_22> | ||||
| Component: | Accessibility | Assignee: | Andres Gonzalez <andresg_22> | ||||
| Status: | RESOLVED FIXED | ||||||
| Severity: | Normal | CC: | andresg_22, cfleizach, webkit-bug-importer | ||||
| Priority: | P2 | Keywords: | InRadar | ||||
| Version: | WebKit Nightly Build | ||||||
| Hardware: | All | ||||||
| OS: | All | ||||||
| Attachments: |
|
||||||
|
Description
Andres Gonzalez
2023-01-04 12:46:18 PST
Created attachment 464335 [details]
Patch
Comment on attachment 464335 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=464335&action=review > Source/WebKit/WebProcess/Plugins/PDF/PDFPlugin.mm:2009 > + return page->chrome().rootViewToScreen(enclosingIntRect(updatedRect)); return page ? page->chrome().rootViewToScreen(enclosingIntRect(updatedRect)); : { }; > Source/WebKit/WebProcess/Plugins/PDF/PDFPlugin.mm:2025 > + return page->chrome().rootViewToScreen(enclosingIntRect(rectInRootViewCoordinates)); return page ? page->chrome().rootViewToScreen(enclosingIntRect(rectInRootViewCoordinates)) : { }; (In reply to chris fleizach from comment #3) > Comment on attachment 464335 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=464335&action=review > > > Source/WebKit/WebProcess/Plugins/PDF/PDFPlugin.mm:2009 > > + return page->chrome().rootViewToScreen(enclosingIntRect(updatedRect)); > > return page ? > page->chrome().rootViewToScreen(enclosingIntRect(updatedRect)); : { }; > > > Source/WebKit/WebProcess/Plugins/PDF/PDFPlugin.mm:2025 > > + return page->chrome().rootViewToScreen(enclosingIntRect(rectInRootViewCoordinates)); > > return page ? > page->chrome().rootViewToScreen(enclosingIntRect(rectInRootViewCoordinates)) > : { }; Unfortunately you can't have an initializer list in a ? : statement. So you would need to do something like ... ? ... : FloatRect(), which is kind of ugly too. Hopefully, in C++ 26 they got that in :-). Committed 258469@main (c7cf1700de11): <https://commits.webkit.org/258469@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 464335 [details]. |