mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 02:37:36 +00:00
LibWeb+Ladybird+Userland: Port window.[alert,confirm,prompt] to String
LibGUI and WebDriver (read: JSON) API boundaries use DeprecatedString, so that is as far as these changes can reach. The one change which isn't just a DeprecatedString to String replacement is handling the "null" prompt response. We previously checked for the null DeprecatedString, whereas we now represent this as an empty Optional<String>.
This commit is contained in:
parent
b4d3fea002
commit
97536e4684
18 changed files with 85 additions and 85 deletions
|
@ -282,7 +282,7 @@ void PageHost::page_did_request_link_context_menu(Web::CSSPixelPoint content_pos
|
|||
m_client.async_did_request_link_context_menu(page().css_to_device_point(content_position).to_type<int>(), url, target, modifiers);
|
||||
}
|
||||
|
||||
void PageHost::page_did_request_alert(DeprecatedString const& message)
|
||||
void PageHost::page_did_request_alert(String const& message)
|
||||
{
|
||||
m_client.async_did_request_alert(message);
|
||||
}
|
||||
|
@ -292,7 +292,7 @@ void PageHost::alert_closed()
|
|||
page().alert_closed();
|
||||
}
|
||||
|
||||
void PageHost::page_did_request_confirm(DeprecatedString const& message)
|
||||
void PageHost::page_did_request_confirm(String const& message)
|
||||
{
|
||||
m_client.async_did_request_confirm(message);
|
||||
}
|
||||
|
@ -302,17 +302,17 @@ void PageHost::confirm_closed(bool accepted)
|
|||
page().confirm_closed(accepted);
|
||||
}
|
||||
|
||||
void PageHost::page_did_request_prompt(DeprecatedString const& message, DeprecatedString const& default_)
|
||||
void PageHost::page_did_request_prompt(String const& message, String const& default_)
|
||||
{
|
||||
m_client.async_did_request_prompt(message, default_);
|
||||
}
|
||||
|
||||
void PageHost::page_did_request_set_prompt_text(DeprecatedString const& text)
|
||||
void PageHost::page_did_request_set_prompt_text(String const& text)
|
||||
{
|
||||
m_client.async_did_request_set_prompt_text(text);
|
||||
}
|
||||
|
||||
void PageHost::prompt_closed(DeprecatedString response)
|
||||
void PageHost::prompt_closed(Optional<String> response)
|
||||
{
|
||||
page().prompt_closed(move(response));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue