diff --git a/Userland/Applications/Browser/InspectorWidget.cpp b/Userland/Applications/Browser/InspectorWidget.cpp index 90b95205c2..f114edd0d6 100644 --- a/Userland/Applications/Browser/InspectorWidget.cpp +++ b/Userland/Applications/Browser/InspectorWidget.cpp @@ -15,8 +15,8 @@ #include #include #include -#include #include +#include #include namespace Browser { @@ -29,7 +29,7 @@ void InspectorWidget::set_selection(Selection selection) return; } - auto* model = verify_cast(m_dom_tree_view->model()); + auto* model = verify_cast(m_dom_tree_view->model()); auto index = model->index_for_node(selection.dom_node_id, selection.pseudo_element); if (!index.is_valid()) { dbgln("InspectorWidget told to inspect non-existent node: {}", selection.to_string()); @@ -131,7 +131,7 @@ void InspectorWidget::set_dom_json(String json) return; m_dom_json = json; - m_dom_tree_view->set_model(Web::DOMTreeModel::create(m_dom_json->view(), *m_dom_tree_view)); + m_dom_tree_view->set_model(WebView::DOMTreeModel::create(m_dom_json->view(), *m_dom_tree_view)); if (m_pending_selection.has_value()) { set_selection(m_pending_selection.release_value()); diff --git a/Userland/Libraries/LibWeb/CMakeLists.txt b/Userland/Libraries/LibWeb/CMakeLists.txt index a604242a69..e6ce88278b 100644 --- a/Userland/Libraries/LibWeb/CMakeLists.txt +++ b/Userland/Libraries/LibWeb/CMakeLists.txt @@ -109,7 +109,6 @@ set(SOURCES DOM/Text.idl DOM/TreeWalker.cpp DOMParsing/InnerHTML.cpp - DOMTreeModel.cpp Dump.cpp Encoding/TextDecoder.cpp Encoding/TextEncoder.cpp diff --git a/Userland/Libraries/LibWebView/CMakeLists.txt b/Userland/Libraries/LibWebView/CMakeLists.txt index 06238edc75..4f9d9ce159 100644 --- a/Userland/Libraries/LibWebView/CMakeLists.txt +++ b/Userland/Libraries/LibWebView/CMakeLists.txt @@ -1,4 +1,5 @@ set(SOURCES + DOMTreeModel.cpp OutOfProcessWebView.cpp WebContentClient.cpp ) diff --git a/Userland/Libraries/LibWeb/DOMTreeModel.cpp b/Userland/Libraries/LibWebView/DOMTreeModel.cpp similarity index 98% rename from Userland/Libraries/LibWeb/DOMTreeModel.cpp rename to Userland/Libraries/LibWebView/DOMTreeModel.cpp index dbfca80b34..404e9b4eed 100644 --- a/Userland/Libraries/LibWeb/DOMTreeModel.cpp +++ b/Userland/Libraries/LibWebView/DOMTreeModel.cpp @@ -12,7 +12,7 @@ #include #include -namespace Web { +namespace WebView { DOMTreeModel::DOMTreeModel(JsonObject dom_tree, GUI::TreeView& tree_view) : m_tree_view(tree_view) @@ -214,7 +214,7 @@ GUI::ModelIndex DOMTreeModel::index_for_node(i32 node_id, Optional #include -namespace Web { +namespace WebView { class DOMTreeModel final : public GUI::Model { public: