mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 05:39:11 +00:00
Ladybird: Add IPC call for creating a new child tab
This will be used for choosing a navigable that requires opening a new tab or new window. Such as calls to window.open(), or specific WebDriver calls.
This commit is contained in:
parent
7245f6f11c
commit
677bdc2a4f
Notes:
sideshowbarker
2024-07-17 08:45:34 +09:00
Author: https://github.com/ADKaster
Commit: 677bdc2a4f
Pull-request: https://github.com/SerenityOS/serenity/pull/23051
Reviewed-by: https://github.com/kalenikaliaksandr
Reviewed-by: https://github.com/trflynn89 ✅
17 changed files with 144 additions and 19 deletions
|
@ -328,10 +328,10 @@ void WebContentClient::did_update_cookie(Web::Cookie::Cookie const& cookie)
|
|||
m_view.on_update_cookie(cookie);
|
||||
}
|
||||
|
||||
Messages::WebContentClient::DidRequestNewTabResponse WebContentClient::did_request_new_tab(Web::HTML::ActivateTab const& activate_tab)
|
||||
Messages::WebContentClient::DidRequestNewWebViewResponse WebContentClient::did_request_new_web_view(Web::HTML::ActivateTab const& activate_tab, Web::HTML::WebViewHints const& hints, Optional<u64> const& page_index)
|
||||
{
|
||||
if (m_view.on_new_tab)
|
||||
return m_view.on_new_tab(activate_tab);
|
||||
if (m_view.on_new_web_view)
|
||||
return m_view.on_new_web_view(activate_tab, hints, page_index);
|
||||
return String {};
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue