From 4dabbdf24771ec620817c2fdcc8c6b730b1a50fe Mon Sep 17 00:00:00 2001 From: Leo Franchi Date: Sat, 24 Mar 2012 17:57:36 -0400 Subject: [PATCH] Disable ref work for now --- src/accounts/spotify/SpotifyPlaylistUpdater.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/accounts/spotify/SpotifyPlaylistUpdater.cpp b/src/accounts/spotify/SpotifyPlaylistUpdater.cpp index 50393c649..da8a16aef 100644 --- a/src/accounts/spotify/SpotifyPlaylistUpdater.cpp +++ b/src/accounts/spotify/SpotifyPlaylistUpdater.cpp @@ -140,8 +140,11 @@ SpotifyPlaylistUpdater::spotifyTracksAdded( const QVariantList& tracks, int star qDebug() << Q_FUNC_INFO << "inserting tracks in middle of tomahawk playlist, from spotify command!" << tracks << startPos << newRev << oldRev; // Uh oh, dont' want to get out of sync!! - Q_ASSERT( m_latestRev == oldRev ); - m_latestRev = newRev; +// Q_ASSERT( m_latestRev == oldRev ); +// m_latestRev = newRev; + + //NOTE: remove 1 from the position, as spotify gives the *newly inserted* position, not the index to insert at + startPos--; playlist()->insertEntries( queries, startPos, playlist()->currentrevision() ); } @@ -152,8 +155,8 @@ SpotifyPlaylistUpdater::spotifyTracksRemoved( const QVariantList& tracks, const { qDebug() << Q_FUNC_INFO << "remove tracks in middle of tomahawk playlist, from spotify command!" << tracks << newRev << oldRev; // Uh oh, dont' want to get out of sync!! - Q_ASSERT( m_latestRev == oldRev ); - m_latestRev = newRev; +// Q_ASSERT( m_latestRev == oldRev ); +// m_latestRev = newRev; QList< plentry_ptr > entries = playlist()->entries();