summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_routes.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2011-12-06 16:46:50 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2011-12-06 16:46:50 +0000
commit946dc070f8ac13308ddf040e13e1da2d4b914c8d (patch)
tree3c6260bada045c9ab11ada991d6cc87b59afaa23 /gtk2_ardour/editor_routes.cc
parent23002098b204e22fa48bd8016329ceae512a2ab2 (diff)
add monitoring column to route group list; make click in blank area of route list and route group list cancel selection and/or name editing
git-svn-id: svn://localhost/ardour2/branches/3.0@10911 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/editor_routes.cc')
-rw-r--r--gtk2_ardour/editor_routes.cc20
1 files changed, 13 insertions, 7 deletions
diff --git a/gtk2_ardour/editor_routes.cc b/gtk2_ardour/editor_routes.cc
index 7af2e42117..8f7dd23abf 100644
--- a/gtk2_ardour/editor_routes.cc
+++ b/gtk2_ardour/editor_routes.cc
@@ -1138,16 +1138,22 @@ EditorRoutes::button_press (GdkEventButton* ev)
return true;
}
+ TreeModel::Path path;
+ TreeViewColumn *tvc;
+ int cell_x;
+ int cell_y;
+
+ if (!_display.get_path_at_pos ((int) ev->x, (int) ev->y, path, tvc, cell_x, cell_y)) {
+ /* cancel selection */
+ _display.get_selection()->unselect_all ();
+ /* end any editing by grabbing focus */
+ _display.grab_focus ();
+ return true;
+ }
+
//Scroll editor canvas to selected track
if (Keyboard::modifier_state_equals (ev->state, Keyboard::PrimaryModifier)) {
- TreeModel::Path path;
- TreeViewColumn *tvc;
- int cell_x;
- int cell_y;
-
- _display.get_path_at_pos ((int) ev->x, (int) ev->y, path, tvc, cell_x, cell_y);
-
// Get the model row.
Gtk::TreeModel::Row row = *_model->get_iter (path);