mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-01 03:40:16 +02:00
* Fixed asserting in AlbumPlaylistInterface.
This commit is contained in:
@@ -42,6 +42,7 @@ AlbumPlaylistInterface::AlbumPlaylistInterface( Tomahawk::Album* album, Tomahawk
|
|||||||
, m_databaseLoaded( false )
|
, m_databaseLoaded( false )
|
||||||
, m_mode( mode )
|
, m_mode( mode )
|
||||||
, m_collection( collection )
|
, m_collection( collection )
|
||||||
|
, m_uuid( uuid() )
|
||||||
, m_album( QWeakPointer< Tomahawk::Album >( album ) )
|
, m_album( QWeakPointer< Tomahawk::Album >( album ) )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -105,7 +106,7 @@ AlbumPlaylistInterface::tracks()
|
|||||||
artistInfo["album"] = m_album.data()->name();
|
artistInfo["album"] = m_album.data()->name();
|
||||||
|
|
||||||
Tomahawk::InfoSystem::InfoRequestData requestData;
|
Tomahawk::InfoSystem::InfoRequestData requestData;
|
||||||
requestData.caller = uuid();
|
requestData.caller = m_uuid;
|
||||||
requestData.input = QVariant::fromValue< Tomahawk::InfoSystem::InfoStringHash >( artistInfo );
|
requestData.input = QVariant::fromValue< Tomahawk::InfoSystem::InfoStringHash >( artistInfo );
|
||||||
requestData.type = Tomahawk::InfoSystem::InfoAlbumSongs;
|
requestData.type = Tomahawk::InfoSystem::InfoAlbumSongs;
|
||||||
requestData.timeoutMillis = 0;
|
requestData.timeoutMillis = 0;
|
||||||
@@ -136,6 +137,9 @@ AlbumPlaylistInterface::tracks()
|
|||||||
void
|
void
|
||||||
AlbumPlaylistInterface::infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData, QVariant output )
|
AlbumPlaylistInterface::infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData, QVariant output )
|
||||||
{
|
{
|
||||||
|
if ( requestData.caller != m_uuid )
|
||||||
|
return;
|
||||||
|
|
||||||
switch ( requestData.type )
|
switch ( requestData.type )
|
||||||
{
|
{
|
||||||
case Tomahawk::InfoSystem::InfoAlbumSongs:
|
case Tomahawk::InfoSystem::InfoAlbumSongs:
|
||||||
|
@@ -87,6 +87,7 @@ private:
|
|||||||
|
|
||||||
Tomahawk::ModelMode m_mode;
|
Tomahawk::ModelMode m_mode;
|
||||||
Tomahawk::collection_ptr m_collection;
|
Tomahawk::collection_ptr m_collection;
|
||||||
|
QString m_uuid;
|
||||||
|
|
||||||
QWeakPointer< Tomahawk::Album > m_album;
|
QWeakPointer< Tomahawk::Album > m_album;
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user