summaryrefslogtreecommitdiff
path: root/Demos/WebView/WebContentClient.cpp
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-07-04 20:57:57 +0200
committerAndreas Kling <kling@serenityos.org>2020-07-04 20:57:57 +0200
commita4b5350aff281680b96e642c19c8f41f2b16b5dd (patch)
treeeae25b7d64ecb55b3410712a7ef669c7fcc7d023 /Demos/WebView/WebContentClient.cpp
parent8476e3933b87031c2ad6cbba21709b88fff5742f (diff)
downloadserenity-a4b5350aff281680b96e642c19c8f41f2b16b5dd.zip
WebContent: Notify client when web content selection changes
The WebContentView widgets reacts to this by requesting a repaint.
Diffstat (limited to 'Demos/WebView/WebContentClient.cpp')
-rw-r--r--Demos/WebView/WebContentClient.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/Demos/WebView/WebContentClient.cpp b/Demos/WebView/WebContentClient.cpp
index 0594c1cf4e..0906edcaa1 100644
--- a/Demos/WebView/WebContentClient.cpp
+++ b/Demos/WebView/WebContentClient.cpp
@@ -60,3 +60,9 @@ void WebContentClient::handle(const Messages::WebContentClient::DidInvalidateCon
// FIXME: Figure out a way to coalesce these messages to reduce unnecessary painting
m_view.notify_server_did_invalidate_content_rect({}, message.content_rect());
}
+
+void WebContentClient::handle(const Messages::WebContentClient::DidChangeSelection&)
+{
+ dbg() << "handle: WebContentClient::DidChangeSelection!";
+ m_view.notify_server_did_change_selection({});
+}