Skip to content

Commit

Permalink
In current trunk m_currentMetadata is a pointer to the object in all_…
Browse files Browse the repository at this point in the history
…music, so this code was causing playcount to be incremented twice. I've commented out the code for now since it may need to be revisited.
  • Loading branch information
stuartm committed Jan 20, 2011
1 parent 37011f2 commit 74ebeae
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions mythplugins/mythmusic/mythmusic/musicplayer.cpp
Expand Up @@ -502,7 +502,7 @@ void MusicPlayer::customEvent(QEvent *event)
if (list.size() >= 3)
{
int volume = list[3].toInt();
if (volume >= 0 && volume <= 100)
if (volume >= 0 && volume <= 100)
setVolume(volume);
}
}
Expand Down Expand Up @@ -929,16 +929,16 @@ void MusicPlayer::updateLastplay()
sendMetadataChangedEvent(m_currentMetadata->ID());
}
// if all_music is still in scope we need to keep that in sync
if (gMusicData->all_music)
{
Metadata *mdata
= gMusicData->all_music->getMetadata(m_currentNode->getInt());
if (mdata)
{
mdata->incPlayCount();
mdata->setLastPlay();
}
}
// if (gMusicData->all_music)
// {
// Metadata *mdata
// = gMusicData->all_music->getMetadata(m_currentNode->getInt());
// if (mdata)
// {
// mdata->incPlayCount();
// mdata->setLastPlay();
// }
// }
}

m_updatedLastplay = true;
Expand Down

0 comments on commit 74ebeae

Please sign in to comment.