1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-03-23 17:29:42 +01:00

Fix Adium plugin with updated notfications

This commit is contained in:
Jeff Mitchell 2012-04-09 13:11:35 -04:00
parent 80a1009aa2
commit bfdc7a3d67

View File

@ -136,13 +136,16 @@ AdiumPlugin::pushInfo( Tomahawk::InfoSystem::InfoPushData pushData )
void
AdiumPlugin::audioStarted( const Tomahawk::InfoSystem::PushInfoPair pushInfoPair )
{
if ( !pushInfoPair.second.canConvert< Tomahawk::InfoSystem::InfoStringHash >() )
if ( !pushInfoPair.second.canConvert< QVariantMap >() )
return;
Tomahawk::InfoSystem::InfoStringHash hash = pushInfoPair.second.value< Tomahawk::InfoSystem::InfoStringHash >();
QVariantMap map = pushInfoPair.second.toMap();
qDebug() << Q_FUNC_INFO;
if ( !map.contains( "trackinfo" ) || !map[ "trackinfo" ].canConvert< Tomahawk::InfoSystem::InfoStringHash >() )
return;
InfoStringHash hash = map[ "trackinfo" ].value< Tomahawk::InfoSystem::InfoStringHash >();
if ( !hash.contains( "title" ) || !hash.contains( "artist" ) )
return;