Fix opening links to in prefs notes (e.g. VST spec)
gtk's default URL open does not work on recent macOS and Windows.
This commit is contained in:
@@ -42,6 +42,7 @@
|
||||
|
||||
#include "pbd/configuration.h"
|
||||
#include "pbd/replace_all.h"
|
||||
#include "pbd/openuri.h"
|
||||
#include "pbd/strsplit.h"
|
||||
|
||||
#include "widgets/frame.h"
|
||||
@@ -110,6 +111,10 @@ OptionEditorComponent::maybe_add_note (OptionEditorPage* p, int n)
|
||||
l->set_use_markup (true);
|
||||
l->set_line_wrap (true);
|
||||
p->table.attach (*l, 1, 3, n, n + 1, FILL | EXPAND);
|
||||
if (_note.find ("<a href=") != _note.npos) {
|
||||
l->property_track_visited_links() = false;
|
||||
l->signal_activate_link().connect ([](std::string const& url) { return PBD::open_uri (url); });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user