| @@ -42,9 +42,8 @@ event::~event ( void ) | |||||
| } | } | ||||
| /* copy constructor */ | /* copy constructor */ | ||||
| event::event ( const event &e ) | |||||
| event::event ( const event &e ) : midievent( e ) | |||||
| { | { | ||||
| *this = e; | |||||
| _link = _next = _prev = NULL; | _link = _next = _prev = NULL; | ||||
| } | } | ||||
| @@ -72,7 +72,7 @@ Grid::~Grid ( void ) | |||||
| } | } | ||||
| /* copy constructor */ | /* copy constructor */ | ||||
| Grid::Grid ( const Grid &rhs ) | |||||
| Grid::Grid ( const Grid &rhs ) : sigc::trackable() | |||||
| { | { | ||||
| _rd = new data( *rhs._rd ); | _rd = new data( *rhs._rd ); | ||||
| _rw = NULL; | _rw = NULL; | ||||
| @@ -620,21 +620,9 @@ Grid::_relink ( void ) | |||||
| _rw->events.relink(); | _rw->events.relink(); | ||||
| } | } | ||||
| void | |||||
| Grid::record_event ( event *e ) | |||||
| { | |||||
| WARNING( "unimplemented" ); | |||||
| /* lock(); */ | |||||
| /* _rw->events.push_back( *e ); */ | |||||
| /* _rw->events.sort(); */ | |||||
| /* unlock(); */ | |||||
| } | |||||
| /* Dump the event list -- used by pattern / phrase dumppers */ | /* Dump the event list -- used by pattern / phrase dumppers */ | ||||
| void | void | ||||
| Grid::dump ( smf *f, int channel, bool translate ) const | |||||
| Grid::dump ( smf *f, int channel ) const | |||||
| { | { | ||||
| data *d = const_cast<data *>(_rd); | data *d = const_cast<data *>(_rd); | ||||
| @@ -642,14 +630,9 @@ Grid::dump ( smf *f, int channel, bool translate ) const | |||||
| for ( event *e = d->events.first(); e; e = e->next() ) | for ( event *e = d->events.first(); e; e = e->next() ) | ||||
| { | { | ||||
| // e->print(); | |||||
| me = *e; | me = *e; | ||||
| me.channel( channel ); | me.channel( channel ); | ||||
| /* if ( me.is_note_on() || me.is_note_off() ) */ | |||||
| /* if ( translate ) */ | |||||
| /* d->mapping.translate( &me ); */ | |||||
| f->write_event( &me ); | f->write_event( &me ); | ||||
| } | } | ||||
| } | } | ||||
| @@ -104,9 +104,6 @@ class Grid : public trackable | |||||
| protected: | protected: | ||||
| unsigned int _height; | unsigned int _height; | ||||
| char *_notes; | char *_notes; | ||||
| char *_name; | char *_name; | ||||
| @@ -155,8 +152,7 @@ public: | |||||
| Viewport viewport; /* used by the Canvas */ | Viewport viewport; /* used by the Canvas */ | ||||
| Grid ( void ); | Grid ( void ); | ||||
| // FIXME: needs to be virtual? | |||||
| ~Grid ( void ); | |||||
| virtual ~Grid ( void ); | |||||
| Grid ( const Grid &rhs ); | Grid ( const Grid &rhs ); | ||||
| int y_to_note ( int y ) const; | int y_to_note ( int y ) const; | ||||
| @@ -226,7 +222,7 @@ public: | |||||
| void resolution ( unsigned int n ); | void resolution ( unsigned int n ); | ||||
| int resolution ( void ) const; | int resolution ( void ) const; | ||||
| void dump ( smf *f, int channel, bool translate ) const; | |||||
| void dump ( smf *f, int channel ) const; | |||||
| void draw ( Canvas *c, int bx, int by, int bw, int bh ); | void draw ( Canvas *c, int bx, int by, int bw, int bh ); | ||||
| void print ( void ) const; | void print ( void ) const; | ||||
| @@ -223,7 +223,7 @@ extern UI *ui; | |||||
| static | static | ||||
| void | void | ||||
| clear_status ( void *arg ) | |||||
| clear_status ( void * ) | |||||
| { | { | ||||
| ui->status->value( "" ); | ui->status->value( "" ); | ||||
| } | } | ||||
| @@ -89,7 +89,7 @@ public: | |||||
| }; | }; | ||||
| midievent ( void ); | midievent ( void ); | ||||
| ~midievent ( void ); | |||||
| virtual ~midievent ( void ); | |||||
| tick_t timestamp ( void ) const; | tick_t timestamp ( void ) const; | ||||
| void timestamp ( tick_t time ); | void timestamp ( tick_t time ); | ||||
| @@ -545,7 +545,7 @@ pattern::save ( const char *name ) const | |||||
| f.open_track( _name, _number ); | f.open_track( _name, _number ); | ||||
| Grid::dump( &f, _channel, true ); | |||||
| Grid::dump( &f, _channel ); | |||||
| f.close_track( length() ); | f.close_track( length() ); | ||||
| } | } | ||||
| @@ -558,7 +558,7 @@ pattern::dump ( smf *f ) const | |||||
| f->write_pattern_info( this ); | f->write_pattern_info( this ); | ||||
| Grid::dump( f, _channel, false ); | |||||
| Grid::dump( f, _channel ); | |||||
| f->close_track( length() ); | f->close_track( length() ); | ||||
| } | } | ||||
| @@ -284,7 +284,7 @@ phrase::dump ( smf *f ) | |||||
| f->cue( true ); | f->cue( true ); | ||||
| Grid::dump( f, 0, false ); | |||||
| Grid::dump( f, 0 ); | |||||
| f->close_track( length() ); | f->close_track( length() ); | ||||
| } | } | ||||
| @@ -46,7 +46,7 @@ static volatile bool _done; | |||||
| * number of 1920 ticks_per_beat in an attempt to reduce the magnitude | * number of 1920 ticks_per_beat in an attempt to reduce the magnitude | ||||
| * of the error. Currently, we keep this behaviour. */ | * of the error. Currently, we keep this behaviour. */ | ||||
| void | void | ||||
| Transport::timebase ( jack_transport_state_t state, jack_nframes_t nframes, jack_position_t *pos, int new_pos, void *arg ) | |||||
| Transport::timebase ( jack_transport_state_t, jack_nframes_t nframes, jack_position_t *pos, int new_pos, void * ) | |||||
| { | { | ||||
| if ( new_pos || ! _done ) | if ( new_pos || ! _done ) | ||||