summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/Port.cpp20
-rw-r--r--src/gui/Port.hpp2
2 files changed, 14 insertions, 8 deletions
diff --git a/src/gui/Port.cpp b/src/gui/Port.cpp
index 92775483..2bdf2e43 100644
--- a/src/gui/Port.cpp
+++ b/src/gui/Port.cpp
@@ -32,6 +32,7 @@
#include "Style.hpp"
#include "WidgetFactory.hpp"
#include "WindowFactory.hpp"
+#include "ingen_config.h"
using namespace Ingen::Client;
using namespace std;
@@ -434,22 +435,27 @@ Port::property_changed(const Raul::URI& key, const Atom& value)
}
}
-void
-Port::set_selected(gboolean b)
+bool
+Port::on_selected(gboolean b)
{
- if (b != get_selected()) {
- Ganv::Port::set_selected(b);
+ if (b) {
SPtr<const PortModel> pm = _port_model.lock();
- if (pm && b) {
+ if (pm) {
SPtr<const BlockModel> block = dynamic_ptr_cast<BlockModel>(pm->parent());
GraphWindow* win = _app.window_factory()->parent_graph_window(block);
if (win && win->documentation_is_visible() && block->plugin_model()) {
+ bool html = false;
+#ifdef HAVE_WEBKIT
+ html = true;
+#endif
const std::string& doc = block->plugin_model()->port_documentation(
- pm->index());
- win->set_documentation(doc, false);
+ pm->index(), html);
+ win->set_documentation(doc, html);
}
}
}
+
+ return true;
}
} // namespace GUI
diff --git a/src/gui/Port.hpp b/src/gui/Port.hpp
index 16fc5cde..24cddd4e 100644
--- a/src/gui/Port.hpp
+++ b/src/gui/Port.hpp
@@ -64,7 +64,7 @@ public:
void activity(const Atom& value);
void disconnected_from(SPtr<Client::PortModel> port);
- void set_selected(gboolean b);
+ bool on_selected(gboolean b);
private:
Port(App& app,