summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/InProcessWebView.cpp
diff options
context:
space:
mode:
authorTimothy Flynn <trflynn89@pm.me>2021-04-11 10:54:11 -0400
committerAndreas Kling <kling@serenityos.org>2021-04-11 18:24:34 +0200
commit1ef48d50ff9b6adeb13186799555ff11d6c7af9d (patch)
treed1b3c9e66976d592b46527a44605fa1d8cb9db09 /Userland/Libraries/LibWeb/InProcessWebView.cpp
parente54837add5e260e2546a1a43966607b2ef039816 (diff)
downloadserenity-1ef48d50ff9b6adeb13186799555ff11d6c7af9d.zip
LibWeb+WebContent: Hook document.cookie to the backend cookie storage
Diffstat (limited to 'Userland/Libraries/LibWeb/InProcessWebView.cpp')
-rw-r--r--Userland/Libraries/LibWeb/InProcessWebView.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/InProcessWebView.cpp b/Userland/Libraries/LibWeb/InProcessWebView.cpp
index 758f9a47a4..4c2b49bdf8 100644
--- a/Userland/Libraries/LibWeb/InProcessWebView.cpp
+++ b/Userland/Libraries/LibWeb/InProcessWebView.cpp
@@ -433,4 +433,17 @@ String InProcessWebView::page_did_request_prompt(const String& message, const St
return {};
}
+String InProcessWebView::page_did_request_cookie(const URL& url)
+{
+ if (on_get_cookie)
+ return on_get_cookie(url);
+ return {};
+}
+
+void InProcessWebView::page_did_set_cookie(const URL& url, const String& cookie)
+{
+ if (on_set_cookie)
+ on_set_cookie(url, cookie);
+}
+
}