Skip to content

Commit

Permalink
EngineSync: Rebname local leader bpm variables (leftover from mixxxdj…
Browse files Browse the repository at this point in the history
  • Loading branch information
Holzhaus committed Aug 6, 2021
1 parent 793b348 commit 5088610
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/engine/sync/enginesync.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -409,23 +409,23 @@ void EngineSync::requestBpmUpdate(Syncable* pSyncable, mixxx::Bpm bpm) {
kLogger.trace() << "EngineSync::requestBpmUpdate" << pSyncable->getGroup() << bpm;
}

mixxx::Bpm mbaseBpm;
mixxx::Bpm mbpm;
mixxx::Bpm leaderBaseBpm;
mixxx::Bpm leaderBpm;
double beatDistance = 0.0;
if (m_pLeaderSyncable) {
mbaseBpm = m_pLeaderSyncable->getBaseBpm();
mbpm = m_pLeaderSyncable->getBpm();
leaderBaseBpm = m_pLeaderSyncable->getBaseBpm();
leaderBpm = m_pLeaderSyncable->getBpm();
beatDistance = m_pLeaderSyncable->getBeatDistance();
}

if (mbaseBpm.isValid()) {
if (leaderBaseBpm.isValid()) {
// update from current leader
pSyncable->updateLeaderBeatDistance(beatDistance);
pSyncable->updateLeaderBpm(mbpm);
pSyncable->updateLeaderBpm(leaderBaseBpm);
} else {
// There is no leader, adopt this bpm as leader value
pSyncable->updateLeaderBeatDistance(0.0);
pSyncable->updateLeaderBpm(bpm);
pSyncable->updateLeaderBpm(leaderBpm);
}
}

Expand Down

0 comments on commit 5088610

Please sign in to comment.