Merge pull request #1570 from curlymorphic/i888

Proposed fix 888 Bar, Beat and Tick should follow dragged timeline
This commit is contained in:
Tres Finocchiaro
2015-01-10 09:25:15 -05:00

View File

@@ -106,12 +106,13 @@ void TimeDisplayWidget::updateTime()
break;
case BarsTicks:
m_majorLCD.setValue( s->getTacts() + 1 );
m_minorLCD.setValue( ( s->getTicks() % s->ticksPerTact() ) /
( s->ticksPerTact() / s->getTimeSigModel().getNumerator() ) +1 );
;
m_milliSecondsLCD.setValue( ( s->getTicks() % s->ticksPerTact() ) %
( s->ticksPerTact() / s->getTimeSigModel().getNumerator() ) );
int tick;
tick = ( s->getMilliseconds() * s->getTempo() * (DefaultTicksPerTact / 4 ) ) / 60000 ;
m_majorLCD.setValue( (int)(tick / s->ticksPerTact() ) + 1);
m_minorLCD.setValue( ( tick % s->ticksPerTact() ) /
( s->ticksPerTact() / s->getTimeSigModel().getNumerator() ) +1 );
m_milliSecondsLCD.setValue( ( tick % s->ticksPerTact() ) %
( s->ticksPerTact() / s->getTimeSigModel().getNumerator() ) );
break;
default: break;