From 2df25f8edf24ecaa918c5164d1f1c67580651d85 Mon Sep 17 00:00:00 2001 From: Humberto Alves Date: Wed, 22 Feb 2023 10:32:59 +0000 Subject: [PATCH] LibGUI: Fix missing parent in LinkLabel open action Fixed a bug where an action was being registered in the global shortcut scope by mistake. --- Userland/Libraries/LibGUI/LinkLabel.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Userland/Libraries/LibGUI/LinkLabel.cpp b/Userland/Libraries/LibGUI/LinkLabel.cpp index 5eaeeb5e0b..bd1e6240df 100644 --- a/Userland/Libraries/LibGUI/LinkLabel.cpp +++ b/Userland/Libraries/LibGUI/LinkLabel.cpp @@ -29,10 +29,12 @@ LinkLabel::LinkLabel(DeprecatedString text) void LinkLabel::setup_actions() { - m_open_action = GUI::Action::create("Show in File Manager", {}, Gfx::Bitmap::load_from_file("/res/icons/16x16/app-file-manager.png"sv).release_value_but_fixme_should_propagate_errors(), [&](const GUI::Action&) { - if (on_click) - on_click(); - }); + m_open_action = GUI::Action::create( + "Show in File Manager", Gfx::Bitmap::load_from_file("/res/icons/16x16/app-file-manager.png"sv).release_value_but_fixme_should_propagate_errors(), [&](const GUI::Action&) { + if (on_click) + on_click(); + }, + this); m_copy_action = CommonActions::make_copy_action([this](auto&) { Clipboard::the().set_plain_text(text()); }, this); }