From 8a9a48fda1cff3a13f0779dc9e1ad9a6d29d2f4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20Lindstr=C3=B6m?= Date: Sun, 9 Oct 2011 14:13:39 +0200 Subject: [PATCH] Style fix --- .../infoplugins/generic/chartsplugin.cpp | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp b/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp index 69ffba174..429e5c376 100644 --- a/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp +++ b/src/libtomahawk/infosystem/infoplugins/generic/chartsplugin.cpp @@ -211,8 +211,8 @@ ChartsPlugin::notInCacheSlot( uint requestId, QHash criteria, foreach( QVariant type, m_chartTypes ) { - if( type.toMap().value( "geo" ).isValid() ) { - + if( type.toMap().value( "geo" ).isValid() ) + { geos.append( type.toMap().value( "geo" ).toString() ); } } @@ -252,10 +252,10 @@ ChartsPlugin::notInCacheSlot( uint requestId, QHash criteria, QList geoTrack_charts; foreach( QVariant type, m_chartTypes ) - { + { + + /// Itunes supplys charts based on geo, create breadcrumb for each of them - /// Itunes supplys charts based on geo, for now, only take US charts - /// @todo: Add new breadcrumb option for country? if( type.toMap().value( "source" ).toString() == chartResource.toString() && type.toMap().value( "geo" ).isValid() ) { @@ -280,17 +280,14 @@ ChartsPlugin::notInCacheSlot( uint requestId, QHash criteria, } } - } } } }else{ - + /// Billboard, and maybe others foreach( QVariant type, m_chartTypes ) { - // && type.toMap().value( "geo" ).toString() != "us" ) - // continue; /// Append each type to its parent source /// @todo Add chartType enum @@ -301,6 +298,7 @@ ChartsPlugin::notInCacheSlot( uint requestId, QHash criteria, album_charts.append( Chart( type.toMap().value("id").toString(), type.toMap().value("name").toString(), "album" ) ); charts.insert( "Albums", QVariant::fromValue >( album_charts ) ); } + if( type.toMap().value( "type" ).toString() == "Track" ) { track_charts.append( Chart( type.toMap().value("id").toString(), type.toMap().value("name").toString(), "tracks" ) );