Adopt new API for not keeping the app foreground.
<rdar://problem/103458234>
Pull request: https://github.com/WebKit/WebKit/pull/10874
Committed 261128@main (41855a914387): <https://commits.webkit.org/261128@main> Reviewed commits have been landed. Closing PR #10874 and removing active labels.