allow dragging plugins directly from the manager
This commit is contained in:
parent
80028d7c82
commit
646bcc6885
@ -105,6 +105,10 @@ PluginSelector::PluginSelector (PluginManager& mgr)
|
||||
plugin_display.set_headers_clickable (true);
|
||||
plugin_display.set_reorderable (false);
|
||||
plugin_display.set_rules_hint (true);
|
||||
plugin_display.add_object_drag (plugin_columns.plugin.index(), "PluginInfoPtr");
|
||||
|
||||
// setting a sort-column prevents re-ordering via Drag/Drop
|
||||
plugin_model->set_sort_column (plugin_columns.name.index(), Gtk::SORT_ASCENDING);
|
||||
|
||||
CellRendererToggle* fav_cell = dynamic_cast<CellRendererToggle*>(plugin_display.get_column_cell_renderer (0));
|
||||
fav_cell->property_activatable() = true;
|
||||
|
@ -23,6 +23,7 @@
|
||||
#include <gtkmm/dialog.h>
|
||||
#include <gtkmm/notebook.h>
|
||||
#include <gtkmm/treeview.h>
|
||||
#include "gtkmm2ext/dndtreeview.h"
|
||||
#include <gtkmm2ext/selector.h>
|
||||
|
||||
#include "ardour/plugin.h"
|
||||
@ -99,7 +100,7 @@ class PluginSelector : public ArdourDialog
|
||||
};
|
||||
PluginColumns plugin_columns;
|
||||
Glib::RefPtr<Gtk::ListStore> plugin_model;
|
||||
Gtk::TreeView plugin_display;
|
||||
Gtkmm2ext::DnDTreeView<ARDOUR::PluginInfoPtr> plugin_display;
|
||||
Gtk::Button* btn_add;
|
||||
Gtk::Button* btn_remove;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user