Oops. Can't pass a pointer to an element of std::vector!

This commit is contained in:
Jonathan Moore Liles 2008-04-28 14:04:16 -05:00
parent 11f420a1a4
commit 311daf498c
3 changed files with 5 additions and 4 deletions

View File

@ -54,6 +54,7 @@ Control_Sequence::init ( void )
{ {
_track = NULL; _track = NULL;
_highlighted = false; _highlighted = false;
_output = NULL;
color( fl_darker( FL_YELLOW ) ); color( fl_darker( FL_YELLOW ) );
} }

View File

@ -357,9 +357,9 @@ Track::add ( Control_Sequence *t )
control->add( t ); control->add( t );
control_out.push_back( Port( Port::Output, name(), control_out.size(), "cv" ) ); control_out.push_back( new Port( Port::Output, name(), control_out.size(), "cv" ) );
t->output( &control_out.back() ); t->output( control_out.back() );
resize(); resize();
} }
@ -517,7 +517,7 @@ Track::update_port_names ( void )
input[ i ].name( name(), i ); input[ i ].name( name(), i );
for ( int i = 0; i < control_out.size(); ++i ) for ( int i = 0; i < control_out.size(); ++i )
control_out[ i ].name( name(), i, "cv" ); control_out[ i ]->name( name(), i, "cv" );
/* /\* tell any attached control sequences to do the same *\/ */ /* /\* tell any attached control sequences to do the same *\/ */

View File

@ -109,7 +109,7 @@ public:
vector<Port> input; /* input ports... */ vector<Port> input; /* input ports... */
vector<Port> output; /* output ports... */ vector<Port> output; /* output ports... */
vector<Port> control_out; /* control ports... */ vector<Port*> control_out; /* control ports... */
Playback_DS *playback_ds; Playback_DS *playback_ds;