mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:27:44 +00:00
LibWeb+WebContent: Hook document.cookie to the backend cookie storage
This commit is contained in:
parent
e54837add5
commit
1ef48d50ff
12 changed files with 66 additions and 5 deletions
|
@ -825,15 +825,17 @@ void Document::completely_finish_loading()
|
|||
dispatch_event(DOM::Event::create(HTML::EventNames::load));
|
||||
}
|
||||
|
||||
String Document::cookie() const
|
||||
String Document::cookie()
|
||||
{
|
||||
// FIXME: Support cookies!
|
||||
if (auto* page = this->page())
|
||||
return page->client().page_did_request_cookie(m_url);
|
||||
return {};
|
||||
}
|
||||
|
||||
void Document::set_cookie(String)
|
||||
void Document::set_cookie(String cookie)
|
||||
{
|
||||
// FIXME: Support cookies!
|
||||
if (auto* page = this->page())
|
||||
page->client().page_did_set_cookie(m_url, cookie);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue