1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:37:35 +00:00

Ladybird+LibWebView: Add an Inspector action to clone a DOM node

This commit is contained in:
Timothy Flynn 2023-12-07 11:13:15 -05:00 committed by Andreas Kling
parent d5d6ff8bf1
commit 7e974f530d
7 changed files with 32 additions and 0 deletions

View file

@ -274,6 +274,16 @@ void InspectorClient::context_menu_create_child_text_node()
m_context_menu_data.clear();
}
void InspectorClient::context_menu_clone_dom_node()
{
VERIFY(m_context_menu_data.has_value());
m_pending_selection = m_content_web_view.clone_dom_node(m_context_menu_data->dom_node_id);
inspect();
m_context_menu_data.clear();
}
void InspectorClient::context_menu_remove_dom_node()
{
VERIFY(m_context_menu_data.has_value());