diff --git a/ChangeLog b/ChangeLog index b5c9e4960..0027cc330 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,31 @@ 2008-06-03 Tobias Doerffel + * plugins/vibed/nine_button_selector.cpp: + * plugins/live_tool/live_tool.cpp: + * include/note_play_handle.h: + * include/track_container.h: + * include/track.h: + * src/tracks/bb_track.cpp: + * src/tracks/instrument_track.cpp: + * src/tracks/pattern.cpp: + * src/core/sample_play_handle.cpp: + * src/core/track.cpp: + renamed muted() to isMuted() and other coding-style fixes + + * src/gui/widgets/automatable_slider.cpp: + * src/gui/widgets/lcd_spinbox.cpp: + * src/gui/widgets/automatable_button.cpp: + use automatableModelView::addDefaultActions() + + * src/gui/widgets/tooltip.cpp: + re-enabled tooltips + + * include/track.h: + * include/track_container.h: + * src/core/track.cpp: + * data/themes/default/led_red.png: + added fully-functional solo-button + * include/automation_editor.h: * src/gui/automation_editor.cpp: fixed broken automation-drawing for floatModels diff --git a/include/note_play_handle.h b/include/note_play_handle.h index 73748cae8..f5cbe0411 100644 --- a/include/note_play_handle.h +++ b/include/note_play_handle.h @@ -221,7 +221,7 @@ public: bool bbTrackMuted( void ) { - return( m_bbTrack && m_bbTrack->muted() ); + return( m_bbTrack && m_bbTrack->isMuted() ); } void setBBTrack( bbTrack * _bb_track ) { diff --git a/plugins/live_tool/live_tool.cpp b/plugins/live_tool/live_tool.cpp index 83a17fa71..c534e0818 100644 --- a/plugins/live_tool/live_tool.cpp +++ b/plugins/live_tool/live_tool.cpp @@ -200,7 +200,7 @@ void liveToolView::toggleInstrument( int _n ) if( _n < engine::getBBTrackContainer()->tracks().count() ) { track * t = engine::getBBTrackContainer()->tracks().at( _n ); - t->setMuted( !t->muted() ); + t->setMuted( !t->isMuted() ); } } diff --git a/plugins/vibed/nine_button_selector.cpp b/plugins/vibed/nine_button_selector.cpp index 92a135354..06de0f601 100644 --- a/plugins/vibed/nine_button_selector.cpp +++ b/plugins/vibed/nine_button_selector.cpp @@ -232,7 +232,6 @@ void nineButtonSelector::button8Clicked( void ) void nineButtonSelector::modelChanged( void ) { - printf("Model Changed %d", model()->value()); updateButton( model()->value() ); } diff --git a/src/core/sample_play_handle.cpp b/src/core/sample_play_handle.cpp index 6bf93a9c9..17f167093 100644 --- a/src/core/sample_play_handle.cpp +++ b/src/core/sample_play_handle.cpp @@ -126,8 +126,8 @@ void samplePlayHandle::play( bool /* _try_parallelizing */, } const fpp_t frames = engine::getMixer()->framesPerPeriod(); - if( !( m_track && m_track->muted() ) - && !( m_bbTrack && m_bbTrack->muted() ) ) + if( !( m_track && m_track->isMuted() ) + && !( m_bbTrack && m_bbTrack->isMuted() ) ) { stereoVolumeVector v = { { m_volumeModel->value(), m_volumeModel->value() } }; diff --git a/src/tracks/bb_track.cpp b/src/tracks/bb_track.cpp index 04b0f3538..3622a26d8 100644 --- a/src/tracks/bb_track.cpp +++ b/src/tracks/bb_track.cpp @@ -89,7 +89,7 @@ void bbTCO::saveSettings( QDomDocument & _doc, QDomElement & _this ) _this.setAttribute( "pos", startPosition() ); } _this.setAttribute( "len", length() ); - _this.setAttribute( "muted", muted() ); + _this.setAttribute( "muted", isMuted() ); _this.setAttribute( "color", m_color ); } @@ -104,7 +104,7 @@ void bbTCO::loadSettings( const QDomElement & _this ) movePosition( _this.attribute( "pos" ).toInt() ); } changeLength( _this.attribute( "len" ).toInt() ); - if( _this.attribute( "muted" ).toInt() != muted() ) + if( _this.attribute( "muted" ).toInt() != isMuted() ) { toggleMute(); } @@ -180,7 +180,7 @@ void bbTCOView::mouseDoubleClickEvent( QMouseEvent * ) void bbTCOView::paintEvent( QPaintEvent * ) { QColor col( m_bbTCO->m_color ); - if( m_bbTCO->getTrack()->muted() || m_bbTCO->muted() ) + if( m_bbTCO->getTrack()->isMuted() || m_bbTCO->isMuted() ) { col = QColor( 160, 160, 160 ); } @@ -218,7 +218,7 @@ void bbTCOView::paintEvent( QPaintEvent * ) p.setPen( QColor( 0, 0, 0 ) ); p.drawText( 2, p.fontMetrics().height() - 1, m_bbTCO->m_name ); - if( m_bbTCO->muted() ) + if( m_bbTCO->isMuted() ) { p.drawPixmap( 3, p.fontMetrics().height() + 1, embed::getIconPixmap( "muted", 16, 16 ) ); @@ -374,7 +374,7 @@ bool bbTrack::play( const midiTime & _start, const fpp_t _frames, for( QList::iterator it = tcos.begin(); it != tcos.end(); ++it ) { - if( !( *it )->muted() && + if( !( *it )->isMuted() && ( *it )->startPosition() >= lastPosition ) { lastPosition = ( *it )->startPosition(); diff --git a/src/tracks/instrument_track.cpp b/src/tracks/instrument_track.cpp index deb1b5674..e352b883f 100644 --- a/src/tracks/instrument_track.cpp +++ b/src/tracks/instrument_track.cpp @@ -175,7 +175,7 @@ void instrumentTrack::processAudioBuffer( sampleFrame * _buf, notePlayHandle * _n ) { // we must not play the sound if this instrumentTrack is muted... - if( muted() || ( _n && _n->bbTrackMuted() ) ) + if( isMuted() || ( _n && _n->bbTrackMuted() ) ) { return; } @@ -548,7 +548,7 @@ bool FASTCALL instrumentTrack::play( const midiTime & _start, { pattern * p = dynamic_cast( *it ); // everything which is not a pattern or muted won't be played - if( p == NULL || ( *it )->muted() ) + if( p == NULL || ( *it )->isMuted() ) { continue; } diff --git a/src/tracks/pattern.cpp b/src/tracks/pattern.cpp index 7dc4c8da9..c8e1e4c30 100644 --- a/src/tracks/pattern.cpp +++ b/src/tracks/pattern.cpp @@ -338,7 +338,7 @@ void pattern::saveSettings( QDomDocument & _doc, QDomElement & _this ) _this.setAttribute( "pos", startPosition() ); } _this.setAttribute( "len", length() ); - _this.setAttribute( "muted", muted() ); + _this.setAttribute( "muted", isMuted() ); _this.setAttribute( "steps", m_steps ); _this.setAttribute( "frozen", m_frozenPattern != NULL ); @@ -368,7 +368,7 @@ void pattern::loadSettings( const QDomElement & _this ) movePosition( _this.attribute( "pos" ).toInt() ); } changeLength( midiTime( _this.attribute( "len" ).toInt() ) ); - if( _this.attribute( "muted" ).toInt() != muted() ) + if( _this.attribute( "muted" ).toInt() != isMuted() ) { toggleMute(); } @@ -932,7 +932,7 @@ void patternView::constructContextMenu( QMenu * _cm ) _cm->addSeparator(); bool freeze_separator = FALSE; - if( !( m_pat->m_instrumentTrack->muted() || m_pat->muted() ) ) + if( !( m_pat->m_instrumentTrack->isMuted() || m_pat->isMuted() ) ) { _cm->addAction( embed::getIconPixmap( "freeze" ), m_pat->m_frozenPattern ? tr( "Refreeze" ) : @@ -1195,8 +1195,8 @@ void patternView::paintEvent( QPaintEvent * ) height() - 2 * TCO_BORDER_WIDTH ); }*/ - if( m_pat->getTrack()->muted() || - m_pat->muted() ) + if( m_pat->getTrack()->isMuted() || + m_pat->isMuted() ) { p.setPen( QColor( 160, 160, 160 ) ); } @@ -1294,7 +1294,7 @@ void patternView::paintEvent( QPaintEvent * ) } p.setFont( pointSize<7>( p.font() ) ); - if( m_pat->muted() || m_pat->getTrack()->muted() ) + if( m_pat->isMuted() || m_pat->getTrack()->isMuted() ) { p.setPen( QColor( 192, 192, 192 ) ); } @@ -1308,7 +1308,7 @@ void patternView::paintEvent( QPaintEvent * ) p.drawText( 2, p.fontMetrics().height() - 1, m_pat->name() ); } - if( m_pat->muted() ) + if( m_pat->isMuted() ) { p.drawPixmap( 3, p.fontMetrics().height() + 1, embed::getIconPixmap( "muted", 16, 16 ) );