diff options
author | Carl Hetherington <carl@carlh.net> | 2009-06-22 00:02:45 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2009-06-22 00:02:45 +0000 |
commit | cfbec44c3351c062d2360615c894db4cb1f8d260 (patch) | |
tree | 4f48fb969e3539830abb0497d467f9603ddf2cb1 /gtk2_ardour/group_tabs.cc | |
parent | 3be717686279a0419437721d88a9f77c14e71f0b (diff) |
Add some more options to the route group list context menu. Fix a crash bug on removing route groups using the tab context menu.
git-svn-id: svn://localhost/ardour2/branches/3.0@5239 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/group_tabs.cc')
-rw-r--r-- | gtk2_ardour/group_tabs.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/gtk2_ardour/group_tabs.cc b/gtk2_ardour/group_tabs.cc index 1dd15b31ba..60eed1c7cf 100644 --- a/gtk2_ardour/group_tabs.cc +++ b/gtk2_ardour/group_tabs.cc @@ -86,12 +86,11 @@ GroupTabs::on_button_press_event (GdkEventButton* ev) } else if (ev->button == 3) { - if (!_menu) { - _menu = new Menu; - MenuList& items = _menu->items (); - items.push_back (MenuElem (_("Edit..."), bind (mem_fun (*this, &GroupTabs::edit_group), t->group))); - items.push_back (MenuElem (_("Remove"), bind (mem_fun (*this, &GroupTabs::remove_group), t->group))); - } + delete _menu; + _menu = new Menu; + MenuList& items = _menu->items (); + items.push_back (MenuElem (_("Edit..."), bind (mem_fun (*this, &GroupTabs::edit_group), t->group))); + items.push_back (MenuElem (_("Remove"), bind (mem_fun (*this, &GroupTabs::remove_group), t->group))); _menu->popup (ev->button, ev->time); |