store void pointers to processor UIs in Processors, and reset ProcessorWindowProxy...
[ardour.git] / gtk2_ardour / automation_streamview.cc
index cdca5ec08ffa0b8aa180c10a6c3a5f9d6dcf50dc..883f0449b3368f0f23d678a0099a24faeece9e1a 100644 (file)
 
 #include <gtkmm2ext/gtk_ui.h>
 
-#include "ardour/midi_playlist.h"
 #include "ardour/midi_region.h"
 #include "ardour/midi_source.h"
-#include "ardour/midi_diskstream.h"
-#include "ardour/midi_track.h"
-#include "ardour/smf_source.h"
 #include "ardour/region_factory.h"
 
 #include "automation_streamview.h"
@@ -79,8 +75,9 @@ AutomationStreamView::add_region_view_internal (boost::shared_ptr<Region> region
 
        if (wfd) {
                boost::shared_ptr<MidiRegion> mr = boost::dynamic_pointer_cast<MidiRegion>(region);
-               if (mr)
+               if (mr) {
                        mr->midi_source()->load_model();
+               }
        }
 
        const boost::shared_ptr<AutomationControl> control = boost::dynamic_pointer_cast<AutomationControl> (
@@ -151,9 +148,7 @@ AutomationStreamView::display_region(AutomationRegionView* region_view)
 void
 AutomationStreamView::set_automation_state (AutoState state)
 {
-       /* XXX: not sure if this is right, but for now the automation state is basically held by
-          the regions' AutomationLists.  Each region is always set to have the same AutoState.
-       */
+       /* Setting the automation state for this view sets the state of all regions' lists to the same thing */
        
        if (region_views.empty()) {
                _pending_automation_state = state;