Summary: | "favourite tracks by" and statistics broken | ||
---|---|---|---|
Product: | [Applications] amarok | Reporter: | Christian Loosli <web> |
Component: | general | Assignee: | Amarok Developers <amarok-bugs-dist> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | 1.4.4 | ||
Target Milestone: | --- | ||
Platform: | Gentoo Packages | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Christian Loosli
2006-11-03 21:00:24 UTC
yes, i can confirm SVN commit 601627 by aoliveira: Favorites on Context Browser and Statistics panel was broken for sqlite BUG: 136791 M +3 -3 contextbrowser.cpp M +2 -2 statistics.cpp --- trunk/extragear/multimedia/amarok/src/contextbrowser.cpp #601626:601627 @@ -2272,7 +2272,7 @@ qb.addReturnValue( QueryBuilder::tabSong, QueryBuilder::valURL ); qb.addReturnValue( QueryBuilder::tabStats, QueryBuilder::valScore ); qb.addReturnValue( QueryBuilder::tabStats, QueryBuilder::valRating ); - qb.excludeFilter( QueryBuilder::tabStats, QueryBuilder::valPlayCounter, "1", QueryBuilder::modeLess ); + qb.addNumericFilter( QueryBuilder::tabStats, QueryBuilder::valPlayCounter, "0", QueryBuilder::modeGreater ); qb.addMatch( QueryBuilder::tabSong, QueryBuilder::valArtistID, QString::number( artist_id ) ); qb.sortBy( QueryBuilder::tabStats, QueryBuilder::valForFavoriteSorting(), true ); qb.setLimit( 0, 10 ); @@ -2890,7 +2890,7 @@ const bool cached = !lyrics.isEmpty() && !EngineController::engine()->isStream(); QString title = EngineController::instance()->bundle().title(); QString artist = EngineController::instance()->bundle().artist(); - + if( title.contains("PREVIEW: buy it at www.magnatune.com", true) >= 1 ) title = title.remove(" (PREVIEW: buy it at www.magnatune.com)"); if( artist.contains("PREVIEW: buy it at www.magnatune.com", true) >= 1 ) @@ -3372,7 +3372,7 @@ { tmpWikiStr = EngineController::instance()->bundle().prettyTitle(); } - + //Hack to make wiki searches work with magnatune preview tracks if (tmpWikiStr.contains( "PREVIEW: buy it at www.magnatune.com" ) >= 1 ) { tmpWikiStr = tmpWikiStr.remove(" (PREVIEW: buy it at www.magnatune.com)" ); --- trunk/extragear/multimedia/amarok/src/statistics.cpp #601626:601627 @@ -336,7 +336,7 @@ qb.addReturnValue( QueryBuilder::tabSong, QueryBuilder::valURL ); qb.addReturnValue( QueryBuilder::tabStats, QueryBuilder::valScore ); qb.addReturnValue( QueryBuilder::tabStats, QueryBuilder::valRating ); - qb.excludeFilter( QueryBuilder::tabStats, QueryBuilder::valForFavoriteSorting(), "1", QueryBuilder::modeLess ); + qb.addNumericFilter( QueryBuilder::tabStats, QueryBuilder::valForFavoriteSorting(), "0", QueryBuilder::modeGreater ); qb.setGoogleFilter( QueryBuilder::tabSong | QueryBuilder::tabArtist, m_filter ); qb.sortBy( QueryBuilder::tabStats, QueryBuilder::valForFavoriteSorting(), true ); qb.setLimit( 0, 50 ); @@ -370,7 +370,7 @@ qb.addReturnValue( QueryBuilder::tabArtist, QueryBuilder::valName ); qb.addReturnValue( QueryBuilder::tabSong, QueryBuilder::valURL ); qb.addReturnValue( QueryBuilder::tabStats, QueryBuilder::valPlayCounter ); - qb.excludeFilter( QueryBuilder::tabStats, QueryBuilder::valPlayCounter, "1", QueryBuilder::modeLess ); + qb.addNumericFilter( QueryBuilder::tabStats, QueryBuilder::valPlayCounter, "0", QueryBuilder::modeGreater ); qb.setGoogleFilter( QueryBuilder::tabSong | QueryBuilder::tabArtist, m_filter ); qb.sortBy( QueryBuilder::tabStats, QueryBuilder::valPlayCounter, true ); qb.setLimit( 0, 50 ); |