logo       
Google Custom Search
    AddThis Social Bookmark Button

Little diff - %playcount in OSD: msg#00185

Subject: Little diff - %playcount in OSD
Hi,
i made this little patch for my friend.
Maybe it will be useful for someone else ;-)

regards
Krzysztof Wozniak (zybex)


-----

  ** LiNuX RuLeZ **
PS.
   ** amaroK RuLeZ Too ** ;-)
Index: osd.cpp
===================================================================
--- osd.cpp     (wersja 417659)
+++ osd.cpp     (kopia robocza)
@@ -428,14 +428,15 @@
            << "%artist" << "%album" << "%title" << "%genre"
            << "%year" << "%track" << "%bitrate" << "%length"
            << "%file" << "%comment"
-           << "%score";
+           << "%score" << "%playcount";
 
     tags   << bundle.prettyTitle()
            << bundle.artist() << bundle.album() << bundle.title() << 
bundle.genre()
            << bundle.year() << bundle.track() << bundle.prettyBitrate()
            << (bundle.length() > 0 ? bundle.prettyLength() : QString::null) 
//ignore '-' and '?'
            << bundle.url().fileName() << bundle.comment()
-           << QString::number( CollectionDB::instance()->getSongPercentage( 
bundle.url().path() ) );
+           << QString::number( CollectionDB::instance()->getSongPercentage( 
bundle.url().path() ) )
+           << QString::number( CollectionDB::instance()->getPlayCount( 
bundle.url().path() ) );
 
     for( QStringList::ConstIterator tok = tokens.begin(), end = tokens.end(), 
tag = tags.begin(); tok != end; ++tok, ++tag )
     {
<Prev in Thread] Current Thread [Next in Thread>