summaryrefslogtreecommitdiff
path: root/Libraries
diff options
context:
space:
mode:
authorNicholas Hollett <niax@niax.co.uk>2020-05-16 14:46:28 +0100
committerAndreas Kling <kling@serenityos.org>2020-05-18 11:27:27 +0200
commit181eacd3ba9cab1736b6557ea43f44cefbad3be8 (patch)
treedc0ae2b17bb20a6d7bcd41287157f91ae7f3e709 /Libraries
parent02cc3ac21fe09836ccd8f8c14dcd624d0e28809c (diff)
downloadserenity-181eacd3ba9cab1736b6557ea43f44cefbad3be8.zip
LibVT: Pass the handler name to Launcher::open_url to control what gets launched
Now we can pick which application gets opened in the context menu for URLs in the Terminal \o/
Diffstat (limited to 'Libraries')
-rw-r--r--Libraries/LibVT/TerminalWidget.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Libraries/LibVT/TerminalWidget.cpp b/Libraries/LibVT/TerminalWidget.cpp
index 80d428e282..c719ea203a 100644
--- a/Libraries/LibVT/TerminalWidget.cpp
+++ b/Libraries/LibVT/TerminalWidget.cpp
@@ -850,8 +850,8 @@ void TerminalWidget::context_menu_event(GUI::ContextMenuEvent& event)
auto icon = Gfx::Bitmap::load_from_file(handler_icon);
- m_context_menu_for_hyperlink->add_action(GUI::Action::create(String::format("Open in %s", handler_name.characters()), move(icon), [this](auto&) {
- Desktop::Launcher::open(m_context_menu_href);
+ m_context_menu_for_hyperlink->add_action(GUI::Action::create(String::format("Open in %s", handler_name.characters()), move(icon), [this, handler](auto&) {
+ Desktop::Launcher::open(m_context_menu_href, handler);
}));
}
m_context_menu_for_hyperlink->add_action(GUI::Action::create("Copy URL", [this](auto&) {