mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-15 19:16:40 +01:00
(merge from 2.0-ongoing -r1911:1912) fix audio clock handling of key press; fix crash bug caused by mapping over a region list selection that includes rows without regions; also merge sampo's redirect undo/state fixes from 2.0-ongoing
git-svn-id: svn://localhost/ardour2/trunk@1913 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
dc348fb613
commit
376c5381ed
8 changed files with 241 additions and 62 deletions
|
|
@ -231,12 +231,19 @@ Editor::region_list_selection_changed()
|
|||
TreeView::Selection::ListHandle_Path::iterator i = rows.begin();
|
||||
TreeIter iter;
|
||||
|
||||
/* just set the first selected region (in fact, the selection model might be SINGLE, which
|
||||
means there can only be one.
|
||||
*/
|
||||
|
||||
if ((iter = region_list_model->get_iter (*i))) {
|
||||
set_selected_regionview_from_region_list (((*iter)[region_list_columns.region]), Selection::Set);
|
||||
boost::shared_ptr<Region> r = (*iter)[region_list_columns.region];
|
||||
|
||||
/* they could have clicked on a row that is just a placeholder, like "Hidden" */
|
||||
|
||||
if (r) {
|
||||
|
||||
/* just set the first selected region (in fact, the selection model might be SINGLE, which
|
||||
means there can only be one.
|
||||
*/
|
||||
|
||||
set_selected_regionview_from_region_list (r, Selection::Set);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -564,7 +571,16 @@ Editor::region_list_selection_mapover (slot<void,boost::shared_ptr<Region> > sl)
|
|||
TreeIter iter;
|
||||
|
||||
if ((iter = region_list_model->get_iter (*i))) {
|
||||
sl (((*iter)[region_list_columns.region]));
|
||||
|
||||
/* some rows don't have a region associated with them, but can still be
|
||||
selected (XXX maybe prevent them from being selected)
|
||||
*/
|
||||
|
||||
boost::shared_ptr<Region> r = (*iter)[region_list_columns.region];
|
||||
|
||||
if (r) {
|
||||
sl (r);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue