Skip to content

Commit

Permalink
Fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
lpugin committed Jan 25, 2024
1 parent 533f30d commit 46e8e90
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/measure.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -496,8 +496,9 @@ const Staff *Measure::GetBottomVisibleStaff() const
int Measure::EnclosesTime(int time) const
{
int repeat = 1;
double timeDuration
= m_measureAligner.GetRightAlignment()->GetTime() * static_cast<int>(DURATION_4) / DUR_MAX * 60.0 / m_currentTempo * 1000.0 + 0.5;
double timeDuration = m_measureAligner.GetRightAlignment()->GetTime() * static_cast<int>(DURATION_4) / DUR_MAX
* 60.0 / m_currentTempo * 1000.0
+ 0.5;
std::vector<double>::const_iterator iter;
for (iter = m_realTimeOffsetMilliseconds.begin(); iter != m_realTimeOffsetMilliseconds.end(); ++iter) {
if ((time >= *iter) && (time <= *iter + timeDuration)) return repeat;
Expand Down
4 changes: 2 additions & 2 deletions src/midifunctor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -239,8 +239,8 @@ FunctorCode InitMaxMeasureDurationFunctor::VisitMeasureEnd(Measure *measure)
const double tempo = this->GetAdjustedTempo();
measure->SetCurrentTempo(tempo);

const double scoreTimeIncrement
= measure->m_measureAligner.GetRightAlignment()->GetTime() * m_multiRestFactor * static_cast<int>(DURATION_4) / DUR_MAX;
const double scoreTimeIncrement = measure->m_measureAligner.GetRightAlignment()->GetTime() * m_multiRestFactor
* static_cast<int>(DURATION_4) / DUR_MAX;
m_currentScoreTime += scoreTimeIncrement;
m_currentRealTimeSeconds += scoreTimeIncrement * 60.0 / tempo;
m_multiRestFactor = 1;
Expand Down

0 comments on commit 46e8e90

Please sign in to comment.