Simplify route-display TreeView.

There's no TargetEntry receiver for the custom DnDTreeView<Route> object.
We can just use a default Gtk::TreeView.
This commit is contained in:
Robin Gareus 2017-06-17 16:48:25 +02:00
parent af2ee3c856
commit cfe63b7b15
2 changed files with 1 additions and 20 deletions

View File

@ -261,7 +261,6 @@ EditorRoutes::EditorRoutes (Editor* e)
_display.set_name (X_("EditGroupList"));
_display.set_rules_hint (true);
_display.set_size_request (100, -1);
_display.add_object_drag (_columns.stripable.index(), "routes");
CellRendererText* name_cell = dynamic_cast<CellRendererText*> (_display.get_column_cell_renderer (_name_column));
@ -1515,20 +1514,6 @@ EditorRoutes::initial_display ()
sync_treeview_from_presentation_info (Properties::order);
}
void
EditorRoutes::display_drag_data_received (const RefPtr<Gdk::DragContext>& context,
int x, int y,
const SelectionData& data,
guint info, guint time)
{
if (data.get_target() == "GTK_TREE_MODEL_ROW") {
_display.on_drag_data_received (context, x, y, data, info, time);
return;
}
context->drag_finish (true, false, time);
}
struct ViewStripable {
TimeAxisView* tav;
boost::shared_ptr<Stripable> stripable;

View File

@ -109,10 +109,6 @@ private:
int plugin_setup (boost::shared_ptr<ARDOUR::Route>, boost::shared_ptr<ARDOUR::PluginInsert>, ARDOUR::Route::PluginSetupOptions);
void display_drag_data_received (
Glib::RefPtr<Gdk::DragContext> const &, gint, gint, Gtk::SelectionData const &, guint, guint
);
bool selection_filter (Glib::RefPtr<Gtk::TreeModel> const &, Gtk::TreeModel::Path const &, bool);
void name_edit (std::string const &, std::string const &);
void solo_changed_so_update_mute ();
@ -157,7 +153,7 @@ private:
};
Gtk::ScrolledWindow _scroller;
Gtkmm2ext::DnDTreeView<boost::shared_ptr<ARDOUR::Route> > _display;
Gtk::TreeView _display;
Glib::RefPtr<Gtk::ListStore> _model;
ModelColumns _columns;
int _name_column;