diff --git a/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp b/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp index bf300eb99..99701a764 100644 --- a/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp +++ b/src/libtomahawk/accounts/spotify/SpotifyAccount.cpp @@ -838,7 +838,7 @@ SpotifyAccount::resolverMessage( const QString &msgType, const QVariantMap &msg const bool isOwner = plMap.value( "owner" ).toBool(); const bool sync = plMap.value( "sync" ).toBool(); const bool subscribed = plMap.value( "subscribed" ).toBool(); - const bool starContainer = plMap.value( "starContainer" ).toBool(); + const bool starContainer = ( plMap.value( "starContainer" ).toBool() || name == "Starred Tracks"); if ( name.isNull() || plid.isNull() || revid.isNull() ) { @@ -1175,7 +1175,7 @@ SpotifyAccount::saveConfig() m_configWidget.data()->saveSettings(); foreach ( SpotifyPlaylistInfo* pl, m_allSpotifyPlaylists.values() ) { -// qDebug() << "Checking changed state:" << pl->changed << pl->name << pl->sync; +// qDebug() << "Checking changed state:" << pl->changed << "name:" << pl->name << "sync" << pl->sync << "starred:" << pl->starContainer; if ( pl->changed ) { pl->changed = false; diff --git a/src/libtomahawk/accounts/spotify/SpotifyAccountConfig.cpp b/src/libtomahawk/accounts/spotify/SpotifyAccountConfig.cpp index 1fe35b289..c7622b3e8 100644 --- a/src/libtomahawk/accounts/spotify/SpotifyAccountConfig.cpp +++ b/src/libtomahawk/accounts/spotify/SpotifyAccountConfig.cpp @@ -101,12 +101,14 @@ SpotifyAccountConfig::saveSettings() const bool toSync = ( item->checkState() == Qt::Checked ); if ( pl->sync != toSync ) { + qDebug() << Q_FUNC_INFO << "Setting sync"; pl->changed = true; pl->sync = toSync; } if ( ( pl->starContainer && loveSync() ) && ( pl->loveSync != loveSync() ) ) { + qDebug() << Q_FUNC_INFO << "Setting lovesync"; pl->loveSync = loveSync(); pl->changed = true; } @@ -161,10 +163,11 @@ SpotifyAccountConfig::setPlaylists( const QList& playlist foreach ( SpotifyPlaylistInfo* pl, myList ) { + bool starContainer = ( pl->starContainer || pl->name == "Starred Tracks" ); QListWidgetItem* item = new QListWidgetItem( pl->name, m_ui->playlistList ); item->setData( Qt::UserRole, QVariant::fromValue< SpotifyPlaylistInfo* >( pl ) ); - item->setData( Qt::UserRole+2, pl->starContainer ); - if( loveSync() && pl->starContainer ) + item->setData( Qt::UserRole+2, starContainer ); + if( loveSync() && starContainer ) item->setHidden(true); item->setFlags( Qt::ItemIsUserCheckable | Qt::ItemIsSelectable | Qt::ItemIsEnabled ); item->setCheckState( pl->sync ? Qt::Checked : Qt::Unchecked );