1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 22:17:44 +00:00

Browser: Display style properties in DOM Inspector

This makes use of the new `inspect_dom_node()` IPC call.
This commit is contained in:
Sam Atkins 2021-09-02 12:05:32 +01:00 committed by Andreas Kling
parent f381f8d63e
commit 1da07734bb
3 changed files with 48 additions and 3 deletions

View file

@ -17,19 +17,28 @@ class InspectorWidget final : public GUI::Widget {
public:
virtual ~InspectorWidget();
void set_web_view(NonnullRefPtr<Web::OutOfProcessWebView> web_view) { m_web_view = web_view; }
void set_dom_json(String);
void set_dom_node_properties_json(i32 node_id, String specified_values_json, String computed_values_json);
private:
InspectorWidget();
void set_inspected_node(GUI::ModelIndex);
RefPtr<Web::OutOfProcessWebView> m_web_view;
RefPtr<GUI::TreeView> m_dom_tree_view;
RefPtr<GUI::TreeView> m_layout_tree_view;
RefPtr<GUI::TableView> m_style_table_view;
RefPtr<GUI::TableView> m_computed_style_table_view;
// Multi-process mode
Optional<String> m_dom_json;
i32 m_inspected_node_id;
Optional<String> m_inspected_node_specified_values_json;
Optional<String> m_inspected_node_computed_values_json;
};
}