mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 22:07:35 +00:00
Browser: Add update_cookie
WebDriver IPC endpoint
Through this the WebDriver will be able to change cookies. Needed for deleting cookies.
This commit is contained in:
parent
30360918d4
commit
c710780852
3 changed files with 12 additions and 0 deletions
|
@ -95,4 +95,14 @@ Messages::WebDriverSessionClient::GetNamedCookieResponse WebDriverConnection::ge
|
|||
return { {} };
|
||||
}
|
||||
|
||||
void WebDriverConnection::update_cookie(Web::Cookie::Cookie const& cookie)
|
||||
{
|
||||
if (auto browser_window = m_browser_window.strong_ref()) {
|
||||
auto& tab = browser_window->active_tab();
|
||||
if (tab.on_update_cookie) {
|
||||
tab.on_update_cookie(tab.url(), cookie);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue