RESOLVED FIXED 227951
[WPE] Implement fullscreen in WPEView
https://bugs.webkit.org/show_bug.cgi?id=227951
Summary [WPE] Implement fullscreen in WPEView
Imanol Fernandez
Reported 2021-07-14 07:27:32 PDT
Implement fullscreen in WPEView: - Notify DOM fullscreen enter request to libwpe - Handle exit fullscreen from libwpe
Attachments
Patch (2.88 KB, patch)
2021-07-14 09:09 PDT, Imanol Fernandez
no flags
Patch (4.17 KB, patch)
2021-07-19 08:27 PDT, Imanol Fernandez
no flags
Patch (4.28 KB, patch)
2021-08-05 10:03 PDT, Imanol Fernandez
no flags
Patch (9.32 KB, patch)
2021-08-06 04:50 PDT, Imanol Fernandez
no flags
Imanol Fernandez
Comment 1 2021-07-14 09:09:15 PDT
Created attachment 433505 [details] Patch wip
Imanol Fernandez
Comment 2 2021-07-19 08:27:08 PDT
Created attachment 433792 [details] Patch Update to latest libwpe API
Adrian Perez
Comment 3 2021-07-27 04:35:19 PDT
As for the WPE build failure, we will need to land the new API in libwpe first, and then update the Flatpak SDK to build a newer revision of libwpe. We should do that in a separate patch that only touches the SDK build recipes :)
Adrian Perez
Comment 4 2021-08-04 13:10:26 PDT
Comment on attachment 433792 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=433792&action=review > Source/WebKit/UIProcess/API/wpe/WPEView.cpp:260 > +#if ENABLE(FULLSCREEN_API) It would be good to make guards check also WPE_CHECK_VERSION(1, 11, 1) to make it possible to build WebKit using older libwpe versions. > Source/WebKit/UIProcess/API/wpe/WPEView.cpp:291 > + wpe_view_backend_set_dom_fullscreen_client(m_backend, &s_fullscreenClient, this); You will need to adapt this to the function name changes in the version of the libwpe PR that we got landed.
Adrian Perez
Comment 5 2021-08-04 13:19:29 PDT
Also I expect that implementing this will make a few more layout tests pass. It would be good to look into enabling them, if so. We might need some work in WKTR (Tools/WebKitTestRunner/wpe/) to provide a fullscreening handler there and also it would be great to make it work in the MiniBrowser (Tools/MiniBrowser/wpe/).
Imanol Fernandez
Comment 6 2021-08-05 10:03:58 PDT
Created attachment 434998 [details] Patch Update to API function name changes. Add WPE version checks
Lauro Moura
Comment 7 2021-08-05 16:56:40 PDT
(In reply to Adrian Perez from comment #4) > > You will need to adapt this to the function name changes in the version > of the libwpe PR that we got landed. The SDK with libwpe 1.11.1 has just landed in the repo.
Imanol Fernandez
Comment 8 2021-08-06 04:50:24 PDT
Created attachment 435062 [details] Patch Implement fullscreen in the minibrowser. Reset state if WPEView->setFullscreen fails
Imanol Fernandez
Comment 9 2021-08-06 04:57:46 PDT
(In reply to Adrian Perez from comment #5) > Also I expect that implementing this will make a few more layout > tests pass. It would be good to look into enabling them, if so. > We might need some work in WKTR (Tools/WebKitTestRunner/wpe/) to > provide a fullscreening handler there and also it would be great > to make it work in the MiniBrowser (Tools/MiniBrowser/wpe/). I have looked into the WKTR tests and confirmed that they are not using the platform PageClientImpl->enterFullScreen path (which calls WPEView->setFullscreen). Instead the WKTR is using fullscreen code from InjectedBundlePage which sets DOM fullscreen state without calling platform fullscreen handlers. I understant that WKTR uses headless testing so it probably doesn't make sense to use real fullscreening here. Adding a WPE fullscreen handler in WKTR would not have any effect. The fullscreen related tests have the same results as before the pathc. (In reply to Lauro Moura from comment #7) > (In reply to Adrian Perez from comment #4) > > > > You will need to adapt this to the function name changes in the version > > of the libwpe PR that we got landed. > > The SDK with libwpe 1.11.1 has just landed in the repo. Great, I already tested with it instead of the local flatpak-sdk build :)
Adrian Perez
Comment 10 2021-08-09 05:27:21 PDT
(In reply to Imanol Fernandez from comment #9) > (In reply to Adrian Perez from comment #5) > > Also I expect that implementing this will make a few more layout > > tests pass. It would be good to look into enabling them, if so. > > We might need some work in WKTR (Tools/WebKitTestRunner/wpe/) to > > provide a fullscreening handler there and also it would be great > > to make it work in the MiniBrowser (Tools/MiniBrowser/wpe/). > > I have looked into the WKTR tests and confirmed that they are not using the > platform PageClientImpl->enterFullScreen path (which calls > WPEView->setFullscreen). Instead the WKTR is using fullscreen code from > InjectedBundlePage which sets DOM fullscreen state without calling platform > fullscreen handlers. I understant that WKTR uses headless testing so it > probably doesn't make sense to use real fullscreening here. Adding a WPE > fullscreen handler in WKTR would not have any effect. The fullscreen related > tests have the same results as before the pathc. > > (In reply to Lauro Moura from comment #7) > > (In reply to Adrian Perez from comment #4) > > > > > > You will need to adapt this to the function name changes in the version > > > of the libwpe PR that we got landed. > > > > The SDK with libwpe 1.11.1 has just landed in the repo. > > Great, I already tested with it instead of the local flatpak-sdk build :) And the EWS passed, too!
Adrian Perez
Comment 11 2021-08-09 05:30:29 PDT
Comment on attachment 435062 [details] Patch The Mac EWS failures are unrelated, so let's land this ^_^
EWS
Comment 12 2021-08-09 05:49:33 PDT
Committed r280774 (240358@main): <https://commits.webkit.org/240358@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 435062 [details].
Note You need to log in before you can comment on or make changes to this bug.