1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 12:07:45 +00:00

LibWeb+WebContent: Add set_preferred_color_scheme IPC call

This allows the owner of a WebView to override whether to use a dark
theme or not, instead of just using the system theme's IsDark property.
This commit is contained in:
Sam Atkins 2021-10-26 17:00:10 +01:00 committed by Linus Groh
parent c8550da9c5
commit 53edaa3b26
11 changed files with 44 additions and 0 deletions

View file

@ -10,6 +10,7 @@
#include <LibIPC/ClientConnection.h>
#include <LibJS/Forward.h>
#include <LibJS/Heap/Handle.h>
#include <LibWeb/CSS/PreferredColorScheme.h>
#include <LibWeb/Cookie/ParsedCookie.h>
#include <LibWeb/Forward.h>
#include <WebContent/Forward.h>
@ -57,6 +58,7 @@ private:
virtual Messages::WebContentServer::GetHoveredNodeIdResponse get_hovered_node_id() override;
virtual Messages::WebContentServer::DumpLayoutTreeResponse dump_layout_tree() override;
virtual void set_content_filters(Vector<String> const&) override;
virtual void set_preferred_color_scheme(Web::CSS::PreferredColorScheme const&) override;
virtual void js_console_input(String const&) override;
virtual void run_javascript(String const&) override;