- TrackViewList const & tvl (editor->get_track_views ());
-
- for (TrackViewList::const_iterator x = tvl.begin(); x != tvl.end(); ++x) {
-
- boost::shared_ptr<Stripable> s = (*x)->stripable ();
- boost::shared_ptr<AutomationControl> c = (*x)->control ();
-
- if (!s) {
- continue;
- }
-
- TimeAxisView* tav = editor->time_axis_view_from_stripable (s);
-
- if (!tav) {
- continue;
+ CoreSelection::StripableAutomationControls sac;
+ selection.get_stripables (sac);
+
+ for (CoreSelection::StripableAutomationControls::const_iterator i = sac.begin(); i != sac.end(); ++i) {
+ AxisView* av;
+ TimeAxisView* tav;
+ if ((*i).controllable) {
+ av = editor->axis_view_by_control ((*i).controllable);
+ } else {
+ av = editor->axis_view_by_stripable ((*i).stripable);