summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/OutOfProcessWebView.h
diff options
context:
space:
mode:
authorSam Atkins <atkinssj@serenityos.org>2022-03-04 16:29:05 +0000
committerAndreas Kling <kling@serenityos.org>2022-03-10 17:30:09 +0100
commit0326ad34dfdd618c8b7b5fbb9f309d1bd8d615fe (patch)
tree238d3f453953646d20be574b332c8f467a7eae64 /Userland/Libraries/LibWeb/OutOfProcessWebView.h
parent2c970b9516cc2a89a119ea60761f947df71ffb46 (diff)
downloadserenity-0326ad34dfdd618c8b7b5fbb9f309d1bd8d615fe.zip
Browser+LibWeb+WebContent: Show style for pseudo-elements :^)
This expands the InspectorWidget::Selection to include an optional PseudoElement, which is then passed over IPC to request style information for it. As noted, this has some pretty big limitations because pseudo-elements don't have DOM nodes: - Declared style has to be recalculated when it's requested. - We don't display the computed style. - We don't display custom properties.
Diffstat (limited to 'Userland/Libraries/LibWeb/OutOfProcessWebView.h')
-rw-r--r--Userland/Libraries/LibWeb/OutOfProcessWebView.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/Userland/Libraries/LibWeb/OutOfProcessWebView.h b/Userland/Libraries/LibWeb/OutOfProcessWebView.h
index 2f168d1c18..a80c757e3c 100644
--- a/Userland/Libraries/LibWeb/OutOfProcessWebView.h
+++ b/Userland/Libraries/LibWeb/OutOfProcessWebView.h
@@ -9,6 +9,7 @@
#include <AK/URL.h>
#include <LibGUI/AbstractScrollableWidget.h>
#include <LibGUI/Widget.h>
+#include <LibWeb/CSS/Selector.h>
#include <LibWeb/Page/Page.h>
#include <LibWeb/WebViewHooks.h>
@@ -40,7 +41,7 @@ public:
String custom_properties_json;
String node_box_sizing_json;
};
- Optional<DOMNodeProperties> inspect_dom_node(i32 node_id);
+ Optional<DOMNodeProperties> inspect_dom_node(i32 node_id, Optional<CSS::Selector::PseudoElement>);
void clear_inspected_dom_node();
i32 get_hovered_node_id();