1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-10 10:01:13 +09:00

LibWeb+WebContent: Remove unused code in BrowsingContext

This commit is contained in:
Aliaksandr Kalenik 2025-02-17 23:57:52 +01:00 committed by Tim Flynn
parent cf7b775709
commit 184ae687c5
Notes: github-actions[bot] 2025-02-18 06:38:18 +00:00
4 changed files with 8 additions and 85 deletions

View file

@ -439,14 +439,11 @@ void ConnectionFromClient::inspect_dom_node(u64 page_id, Web::UniqueNodeID const
if (!page.has_value())
return;
auto& top_context = page->page().top_level_browsing_context();
top_context.for_each_in_inclusive_subtree([&](auto& ctx) {
if (ctx.active_document() != nullptr) {
ctx.active_document()->set_inspected_node(nullptr, {});
for (auto& navigable : Web::HTML::all_navigables()) {
if (navigable->active_document() != nullptr) {
navigable->active_document()->set_inspected_node(nullptr, {});
}
return Web::TraversalDecision::Continue;
});
}
auto* node = Web::DOM::Node::from_unique_id(node_id);
// Note: Nodes without layout (aka non-visible nodes, don't have style computed)