Update to 2.2.2 with a post-release patch:
Changes since 2.2.2 Beta 1 * The inline playlist editor now also allows resizing of auto sized items that are invisible because fixed sized items already use up 100% width. * Enhanced the playlist sorting breadcrumb items to separately highlight the order inversion arrow on hover. (BR 209011) * The automatic character set detection for tags has been disabled; it caused too many problems with legitimate UTF-8 tags. It can be re-enabled from Settings->Collection. (Many BRs) * Dynamic mode is now automatically disabled when replacing the playlist. (BR 214759) * The collection search filter now also searches for file names as a fallback. Patch by Andreas Hartmetz . Bugfixes * Fixed crash with dangling pointer on trying to play a media device track whose collection no longer exists. (BR 210477) * Fixed loading MusicBrainz-tagged tracks in dynamic playlists. (BR 219902) * Fixed MusicBrainz-tagged tracks not being restored in the playlist upon restart. * Fixed incorrect display of rich text in applet header text. (BR 220714) * Fixed GUI freezing after mounting and during parse of media devices. (BR 180520) * Fixed occasional crash when custom biases go awry. (BR 219888) * Fixed missing icons in the drag overlay menu. * More reliable MimeType detection for music formats. Patch by Rafa * Fixed regression causing many scripted services, including the, shipped by default, LibriVox service to not work at all. * Fixed corner case that could prevent scans from being completed, manifesting as a regression in 2.2.1. Huge thanks to Christian Kreibichfor his patience and time in helping to debug this. * Fixed removing multiple tracks from a saved playlist only removing the first track. (BR 218527) * Fixed cancel button not responding when loading thumbnails in the cover manager. (BR 204882) * Fixed crash when using the inline playlist editor to resize items containing auto sized elements not shown becuase of all space already being used. (BR 218167) * Fixed relative links in wikipedia work. (BR 218512) * Fixed multilevel playlist sorting by time since last played so it sorts numerically rather than alphabetically. (BR 214761) * Fixed crash with "Edit Track Details" dialog. (BR 217625) * Fixed a number of cases where markers such as "current track", "stop after this track" and others would get shown in both group header and the first track in the group. (BR 197842) * Fixed regression causing non default moodbar styles to not work. * Jamendo.com service: Fixed track lengths not getting shown for most tracks. For existing installs, this requires a redownload of the Jamendo database. (BR 200531) * Jamendo.com service: Fixed searches not working because of SQL errors. * Jamendo.com service: Removed broken "Unknown" genre which would freeze Amarok if expanded. For existing installs, this requires a redownload of the Jamendo database. (BR 213165) * Playback of Audio CD track now correctly stops if track is the last in the playlist. (BR 216175) * Fixed crash if user clicks rating widget on the current track applet while no track is playing (which is possible since there is a slight delay before the applet switches "mode"). (BR 215471) * Made "Last.fm Love" (and potentially other global actions available for all tracks) correctly show up in the Current Track applet.
This commit is contained in:
parent
3a55fec357
commit
f8ae7dff67
5 changed files with 442 additions and 11 deletions
|
@ -1,13 +1,13 @@
|
|||
# $NetBSD: Makefile,v 1.21 2009/12/24 13:49:54 thomasklausner Exp $
|
||||
# $NetBSD: Makefile,v 1.22 2010/01/13 13:37:33 thomasklausner Exp $
|
||||
#
|
||||
|
||||
DISTNAME= amarok-${VERS}
|
||||
VERS= 2.2.1.90
|
||||
VERS= 2.2.2
|
||||
CATEGORIES= audio multimedia
|
||||
MASTER_SITES= http://download.kde.org/unstable/amarok/${VERS}/src/ \
|
||||
ftp://gd.tuwien.ac.at/kde/unstable/amarok/${VERS}/src/
|
||||
#MASTER_SITES= http://download.kde.org/stable/amarok/${VERS}/src/ \
|
||||
# ftp://gd.tuwien.ac.at/kde/stable/amarok/${VERS}/src/
|
||||
#MASTER_SITES= http://download.kde.org/unstable/amarok/${VERS}/src/ \
|
||||
# ftp://gd.tuwien.ac.at/kde/unstable/amarok/${VERS}/src/
|
||||
MASTER_SITES= http://download.kde.org/stable/amarok/${VERS}/src/ \
|
||||
ftp://gd.tuwien.ac.at/kde/stable/amarok/${VERS}/src/
|
||||
EXTRACT_SUFX= .tar.bz2
|
||||
|
||||
MAINTAINER= wiz@NetBSD.org
|
||||
|
|
48
amarok/PLIST
48
amarok/PLIST
|
@ -1,4 +1,4 @@
|
|||
@comment $NetBSD: PLIST,v 1.13 2009/12/24 13:49:54 thomasklausner Exp $
|
||||
@comment $NetBSD: PLIST,v 1.14 2010/01/13 13:37:33 thomasklausner Exp $
|
||||
bin/amarok
|
||||
bin/amarok_afttagger
|
||||
bin/amarokcollectionscanner
|
||||
|
@ -84,6 +84,7 @@ share/kde/apps/amarok/icons/hicolor/16x16/actions/amarok_playlist_clear.png
|
|||
share/kde/apps/amarok/icons/hicolor/16x16/actions/amarok_playlist_refresh.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/amarok_scripts.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/amarok_track.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/collection-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/collection-refresh-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/collection-rescan-amarok.png
|
||||
|
@ -126,6 +127,13 @@ share/kde/apps/amarok/icons/hicolor/16x16/actions/media-album-shuffle-amarok.png
|
|||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-playlist-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-playlist-repeat-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-playlist-shuffle-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-random-albums-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-random-tracks-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-repeat-album-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-repeat-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-repeat-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-show-active-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-standard-track-progression-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-track-add-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-track-edit-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/16x16/actions/media-track-queue-amarok.png
|
||||
|
@ -159,6 +167,7 @@ share/kde/apps/amarok/icons/hicolor/22x22/actions/amarok_playlist_clear.png
|
|||
share/kde/apps/amarok/icons/hicolor/22x22/actions/amarok_playlist_refresh.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/amarok_scripts.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/amarok_track.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/collection-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/collection-refresh-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/collection-rescan-amarok.png
|
||||
|
@ -173,9 +182,17 @@ share/kde/apps/amarok/icons/hicolor/22x22/actions/love-amarok.png
|
|||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-album-cover-manager-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-album-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-album-shuffle-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-playlist-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-playlist-repeat-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-playlist-shuffle-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-random-albums-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-random-tracks-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-repeat-album-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-repeat-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-repeat-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-show-active-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-standard-track-progression-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-track-add-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-track-edit-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/22x22/actions/media-track-queue-amarok.png
|
||||
|
@ -209,6 +226,7 @@ share/kde/apps/amarok/icons/hicolor/32x32/actions/amarok_playlist_refresh.png
|
|||
share/kde/apps/amarok/icons/hicolor/32x32/actions/amarok_scripts.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/amarok_track.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/audioscrobbler.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/collection-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/collection-refresh-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/collection-rescan-amarok.png
|
||||
|
@ -224,9 +242,17 @@ share/kde/apps/amarok/icons/hicolor/32x32/actions/media-album-cover.png
|
|||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-album-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-album-shuffle-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-album-track.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-playlist-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-playlist-repeat-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-playlist-shuffle-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-random-albums-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-random-tracks-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-repeat-album-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-repeat-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-repeat-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-show-active-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-standard-track-progression-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-track-add-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-track-edit-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/32x32/actions/media-track-queue-amarok.png
|
||||
|
@ -259,9 +285,11 @@ share/kde/apps/amarok/icons/hicolor/48x48/actions/amarok_playlist_clear.png
|
|||
share/kde/apps/amarok/icons/hicolor/48x48/actions/amarok_playlist_refresh.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/amarok_scripts.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/amarok_track.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/collection-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/collection-refresh-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/collection-rescan-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/current-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/download-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/dynamic-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/edit-redo-amarok.png
|
||||
|
@ -291,25 +319,36 @@ share/kde/apps/amarok/icons/hicolor/48x48/actions/filename-title-amarok.png
|
|||
share/kde/apps/amarok/icons/hicolor/48x48/actions/filename-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/filename-underscore-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/filename-year-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/info-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/love-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-album-cover-manager-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-album-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-album-shuffle-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-clear-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-playlist-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-playlist-repeat-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-playlist-shuffle-off-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-random-albums-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-random-tracks-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-repeat-album-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-repeat-playlist-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-repeat-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-show-active-track-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-standard-track-progression-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-track-add-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-track-edit-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-track-queue-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-track-remove-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/media-track-repeat-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/music-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/photos-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/podcast-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/preferences-indicator-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/preferences-media-playback-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/preferences-multimedia-player-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/preferences-view-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/remove-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/videoclip-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/view-media-visualization-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/view-services-ampache-amarok.png
|
||||
share/kde/apps/amarok/icons/hicolor/48x48/actions/view-services-jamendo-amarok.png
|
||||
|
@ -477,6 +516,7 @@ share/locale/de/LC_MESSAGES/amarok.mo
|
|||
share/locale/de/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/de/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
share/locale/de/LC_MESSAGES/amarokpkg.mo
|
||||
share/locale/el/LC_MESSAGES/amarok.mo
|
||||
share/locale/en_GB/LC_MESSAGES/amarok.mo
|
||||
share/locale/en_GB/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/en_GB/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
|
@ -541,6 +581,10 @@ share/locale/ru/LC_MESSAGES/amarok.mo
|
|||
share/locale/ru/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/ru/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
share/locale/ru/LC_MESSAGES/amarokpkg.mo
|
||||
share/locale/sl/LC_MESSAGES/amarok.mo
|
||||
share/locale/sl/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/sl/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
share/locale/sl/LC_MESSAGES/amarokpkg.mo
|
||||
share/locale/sr/LC_MESSAGES/amarok.mo
|
||||
share/locale/sr/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/sr/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
|
@ -558,6 +602,8 @@ share/locale/uk/LC_MESSAGES/amarok.mo
|
|||
share/locale/uk/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/uk/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
share/locale/uk/LC_MESSAGES/amarokpkg.mo
|
||||
share/locale/wa/LC_MESSAGES/amarok.mo
|
||||
share/locale/wa/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
share/locale/zh_CN/LC_MESSAGES/amarok.mo
|
||||
share/locale/zh_CN/LC_MESSAGES/amarok_scriptengine_qscript.mo
|
||||
share/locale/zh_CN/LC_MESSAGES/amarokcollectionscanner_qt.mo
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
$NetBSD: distinfo,v 1.16 2009/12/24 13:49:54 thomasklausner Exp $
|
||||
$NetBSD: distinfo,v 1.17 2010/01/13 13:37:33 thomasklausner Exp $
|
||||
|
||||
SHA1 (amarok-2.2.1.90.tar.bz2) = 3441631c2c8ba589f13c8d2fb26dd2f3b97de451
|
||||
RMD160 (amarok-2.2.1.90.tar.bz2) = 6a01be2c80cadead1ae1b50c6c53464311091151
|
||||
Size (amarok-2.2.1.90.tar.bz2) = 8572570 bytes
|
||||
SHA1 (amarok-2.2.2.tar.bz2) = 2075299b856477cf55cba8ba983ea25a93dc139b
|
||||
RMD160 (amarok-2.2.2.tar.bz2) = 0782c4b032d318179bd8bb91353f8e33772d2912
|
||||
Size (amarok-2.2.2.tar.bz2) = 8788107 bytes
|
||||
SHA1 (patch-aa) = 524a9563db17cbf5e234f2ebe261820326e5d30d
|
||||
SHA1 (patch-ab) = 62beea32f17ce6e138702e740d089c6257ddfced
|
||||
SHA1 (patch-ac) = c8c111d0927efe56a07ce89b2ec788a6364257aa
|
||||
|
|
369
amarok/patches/patch-aa
Normal file
369
amarok/patches/patch-aa
Normal file
|
@ -0,0 +1,369 @@
|
|||
$NetBSD: patch-aa,v 1.10 2010/01/13 13:37:33 thomasklausner Exp $
|
||||
|
||||
post-2.2.2 patch from upstream
|
||||
|
||||
--- src/collection/sqlcollection/ScanResultProcessor.cpp.orig 2010-01-06 22:19:46.000000000 +0000
|
||||
+++ src/collection/sqlcollection/ScanResultProcessor.cpp
|
||||
@@ -42,19 +42,59 @@ ScanResultProcessor::ScanResultProcessor
|
||||
ScanResultProcessor::~ScanResultProcessor()
|
||||
{
|
||||
//everything has a URL, so enough to just delete from here
|
||||
+ QSet<QStringList*> currSet; //prevent double deletes
|
||||
foreach( QStringList *list, m_urlsHashByUid )
|
||||
- delete list;
|
||||
+ {
|
||||
+ if( list )
|
||||
+ {
|
||||
+ if( !currSet.contains( list ) )
|
||||
+ {
|
||||
+ delete list;
|
||||
+ currSet.insert( list );
|
||||
+ }
|
||||
+ }
|
||||
+ else
|
||||
+ debug() << "GAAH! Tried to double-delete a value in m_urlsHashByUid";
|
||||
+ }
|
||||
foreach( QLinkedList<QStringList*> *list, m_albumsHashByName )
|
||||
{
|
||||
- foreach( QStringList *slist, *list )
|
||||
- delete slist;
|
||||
- delete list;
|
||||
+ if( list )
|
||||
+ {
|
||||
+ foreach( QStringList *slist, *list )
|
||||
+ {
|
||||
+ if( slist )
|
||||
+ {
|
||||
+ if( !currSet.contains( slist ) )
|
||||
+ {
|
||||
+ delete slist;
|
||||
+ currSet.insert( slist );
|
||||
+ }
|
||||
+ else
|
||||
+ debug() << "GAAH! Tried to double-delete a value in m_albumsHashByName";
|
||||
+ }
|
||||
+ }
|
||||
+ delete list;
|
||||
+ }
|
||||
}
|
||||
foreach( QLinkedList<QStringList*> *list, m_tracksHashByAlbum )
|
||||
{
|
||||
- foreach( QStringList *slist, *list )
|
||||
- delete slist;
|
||||
- delete list;
|
||||
+ if( list )
|
||||
+ {
|
||||
+ foreach( QStringList *slist, *list )
|
||||
+ {
|
||||
+ if( slist )
|
||||
+ {
|
||||
+ if( !currSet.contains( slist ) )
|
||||
+ {
|
||||
+ delete slist;
|
||||
+ currSet.insert( slist );
|
||||
+ }
|
||||
+ else
|
||||
+ debug() << "GAAH! Tried to double-delete a value in m_tracksHashByAlbum";
|
||||
+ }
|
||||
+ }
|
||||
+ delete list;
|
||||
+ }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -67,11 +107,11 @@ ScanResultProcessor::setScanType( ScanTy
|
||||
void
|
||||
ScanResultProcessor::addDirectory( const QString &dir, uint mtime )
|
||||
{
|
||||
- DEBUG_BLOCK
|
||||
- debug() << "SRP::addDirectory on " << dir << " with mtime " << mtime;
|
||||
+ //DEBUG_BLOCK
|
||||
+ //debug() << "SRP::addDirectory on " << dir << " with mtime " << mtime;
|
||||
if( dir.isEmpty() )
|
||||
{
|
||||
- debug() << "got directory with no path from the scanner, not adding";
|
||||
+ //debug() << "got directory with no path from the scanner, not adding";
|
||||
return;
|
||||
}
|
||||
setupDatabase();
|
||||
@@ -254,7 +294,7 @@ ScanResultProcessor::rollback()
|
||||
void
|
||||
ScanResultProcessor::processDirectory( const QList<QVariantMap > &data )
|
||||
{
|
||||
-// DEBUG_BLOCK
|
||||
+ //DEBUG_BLOCK
|
||||
setupDatabase();
|
||||
//using the following heuristics:
|
||||
//if more than one album is in the dir, use the artist of each track as albumartist
|
||||
@@ -274,24 +314,54 @@ ScanResultProcessor::processDirectory( c
|
||||
if( row.value( Field::ALBUM ).toString() != album )
|
||||
multipleAlbums = true;
|
||||
}
|
||||
+
|
||||
if( multipleAlbums || album.isEmpty() || artists.size() == 1 )
|
||||
{
|
||||
foreach( const QVariantMap &row, data )
|
||||
{
|
||||
- int artist = genericId( &m_artists, row.value( Field::ARTIST ).toString(), &m_nextArtistNum );
|
||||
- addTrack( row, artist );
|
||||
+ QString uid = row.value( Field::UNIQUEID ).toString();
|
||||
+ if( m_uidsSeenThisScan.contains( uid ) )
|
||||
+ {
|
||||
+ QString originalLocation = ( ( m_urlsHashByUid.contains( uid ) &&
|
||||
+ m_urlsHashByUid[uid] != 0 ) ?
|
||||
+ MountPointManager::instance()->getAbsolutePath( m_urlsHashByUid[uid]->at( 1 ).toInt(), m_urlsHashByUid[uid]->at( 2 ) ) : "(unknown)" );
|
||||
+ debug() << "Skipping file with uniqueid " << uid << " as it was already seen this scan," <<
|
||||
+ "file is at " << row.value( Field::URL ).toString() << ", original file is at " << originalLocation;
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ int artist = genericId( &m_artists, row.value( Field::ARTIST ).toString(), &m_nextArtistNum );
|
||||
+ //debug() << "artist found = " << artist;
|
||||
+ addTrack( row, artist );
|
||||
+ m_uidsSeenThisScan.insert( uid );
|
||||
+ }
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
QString albumArtist = findAlbumArtist( artists, data.count() );
|
||||
+ //debug() << "albumArtist found = " << albumArtist;
|
||||
//an empty string means that no albumartist was found
|
||||
int artist = albumArtist.isEmpty() ? 0 : genericId( &m_artists, albumArtist, &m_nextArtistNum );
|
||||
+ //debug() << "artist found = " << artist;
|
||||
|
||||
//debug() << "albumartist " << albumArtist << "for artists" << artists;
|
||||
foreach( const QVariantMap &row, data )
|
||||
{
|
||||
- addTrack( row, artist );
|
||||
+ QString uid = row.value( Field::UNIQUEID ).toString();
|
||||
+ if( m_uidsSeenThisScan.contains( uid ) )
|
||||
+ {
|
||||
+ QString originalLocation = ( ( m_urlsHashByUid.contains( uid ) &&
|
||||
+ m_urlsHashByUid[uid] != 0 ) ?
|
||||
+ MountPointManager::instance()->getAbsolutePath( m_urlsHashByUid[uid]->at( 1 ).toInt(), m_urlsHashByUid[uid]->at( 2 ) ) : "(unknown)" );
|
||||
+ debug() << "Skipping file with uniqueid " << uid << " as it was already seen this scan," <<
|
||||
+ "file is at " << row.value( Field::URL ).toString() << ", original file is at " << originalLocation;
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ addTrack( row, artist );
|
||||
+ m_uidsSeenThisScan.insert( uid );
|
||||
+ }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -299,6 +369,7 @@ ScanResultProcessor::processDirectory( c
|
||||
QString
|
||||
ScanResultProcessor::findAlbumArtist( const QSet<QString> &artists, int trackCount ) const
|
||||
{
|
||||
+ //DEBUG_BLOCK
|
||||
QMap<QString, int> artistCount;
|
||||
bool featuring;
|
||||
QStringList trackArtists;
|
||||
@@ -371,6 +442,7 @@ void
|
||||
ScanResultProcessor::addTrack( const QVariantMap &trackData, int albumArtistId )
|
||||
{
|
||||
//DEBUG_BLOCK
|
||||
+ //debug() << "albumArtistId = " << albumArtistId;
|
||||
//amarok 1 stored all tracks of a compilation in different directories.
|
||||
//when using its "Organize Collection" feature
|
||||
//try to detect these cases
|
||||
@@ -419,7 +491,15 @@ ScanResultProcessor::addTrack( const QVa
|
||||
|
||||
//urlId will take care of the urls table part of AFT
|
||||
int url = urlId( path, uid );
|
||||
-
|
||||
+/*
|
||||
+ foreach( QString key, m_urlsHashByUid.keys() )
|
||||
+ debug() << "Key: " << key << ", list: " << *m_urlsHashByUid[key];
|
||||
+ foreach( int key, m_urlsHashById.keys() )
|
||||
+ debug() << "Key: " << key << ", list: " << *m_urlsHashById[key];
|
||||
+ typedef QPair<int, QString> blahType; //QFOREACH is stupid when it comes to QPairs
|
||||
+ foreach( blahType key, m_urlsHashByLocation.keys() )
|
||||
+ debug() << "Key: " << key << ", list: " << *m_urlsHashByLocation[key];
|
||||
+*/
|
||||
QStringList *trackList = new QStringList();
|
||||
int id = m_nextTrackNum;
|
||||
//debug() << "Appending new track number with tracknum: " << id;
|
||||
@@ -470,7 +550,7 @@ ScanResultProcessor::addTrack( const QVa
|
||||
//insert into hashes
|
||||
if( m_tracksHashByUrl.contains( url ) && m_tracksHashByUrl[url] != 0 )
|
||||
{
|
||||
- //debug() << "m_tracksHashByUrl contains the url!";
|
||||
+ //debug() << "m_tracksHashByUrl already contains url " << url;
|
||||
//need to replace, not overwrite/add a new one
|
||||
QStringList *oldValues = m_tracksHashByUrl[url];
|
||||
QString oldId = oldValues->at( 0 );
|
||||
@@ -490,8 +570,24 @@ ScanResultProcessor::addTrack( const QVa
|
||||
m_tracksHashById.insert( id, trackList );
|
||||
}
|
||||
|
||||
+ //debug() << "album = " << album;
|
||||
+
|
||||
if( m_tracksHashByAlbum.contains( album ) && m_tracksHashByAlbum[album] != 0 )
|
||||
- m_tracksHashByAlbum[album]->append( trackList );
|
||||
+ {
|
||||
+ //contains isn't the fastest on linked lists, but in reality this is on the order of maybe
|
||||
+ //ten quick pointer comparisons per track on average...probably lower
|
||||
+ //debug() << "trackList is " << trackList;
|
||||
+ if( !m_tracksHashByAlbum[album]->contains( trackList ) )
|
||||
+ {
|
||||
+ //debug() << "appending trackList to m_tracksHashByAlbum";
|
||||
+ m_tracksHashByAlbum[album]->append( trackList );
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ //debug() << "not appending trackList to m_tracksHashByAlbum";
|
||||
+ }
|
||||
+
|
||||
+ }
|
||||
else
|
||||
{
|
||||
QLinkedList<QStringList*> *list = new QLinkedList<QStringList*>();
|
||||
@@ -595,6 +691,8 @@ ScanResultProcessor::albumId( const QStr
|
||||
QLinkedList<QStringList*> *list = m_albumsHashByName[album];
|
||||
foreach( QStringList *slist, *list )
|
||||
{
|
||||
+ //debug() << "albumArtistId = " << albumArtistId;
|
||||
+ //debug() << "Checking list: " << *slist;
|
||||
if( slist->at( 2 ).isEmpty() && albumArtistId == 0 )
|
||||
{
|
||||
//debug() << "artist is empty and albumArtistId = 0, returning " << slist->at( 0 );
|
||||
@@ -631,7 +729,10 @@ ScanResultProcessor::albumInsert( const
|
||||
albumList->append( QString() );
|
||||
m_albumsHashById[returnedNum] = albumList;
|
||||
if( m_albumsHashByName.contains( album ) && m_albumsHashByName[album] != 0 )
|
||||
- m_albumsHashByName[album]->append( albumList );
|
||||
+ {
|
||||
+ if( !m_albumsHashByName[album]->contains( albumList ) )
|
||||
+ m_albumsHashByName[album]->append( albumList );
|
||||
+ }
|
||||
else
|
||||
{
|
||||
QLinkedList<QStringList*> *list = new QLinkedList<QStringList*>();
|
||||
@@ -645,7 +746,7 @@ ScanResultProcessor::albumInsert( const
|
||||
int
|
||||
ScanResultProcessor::urlId( const QString &url, const QString &uid )
|
||||
{
|
||||
- /*
|
||||
+/*
|
||||
DEBUG_BLOCK
|
||||
foreach( QString key, m_urlsHashByUid.keys() )
|
||||
debug() << "Key: " << key << ", list: " << *m_urlsHashByUid[key];
|
||||
@@ -654,8 +755,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
typedef QPair<int, QString> blahType; //QFOREACH is stupid when it comes to QPairs
|
||||
foreach( blahType key, m_urlsHashByLocation.keys() )
|
||||
debug() << "Key: " << key << ", list: " << *m_urlsHashByLocation[key];
|
||||
- */
|
||||
-
|
||||
+*/
|
||||
QFileInfo fileInfo( url );
|
||||
const QString dir = fileInfo.absoluteDir().absolutePath();
|
||||
int dirId = directoryId( dir );
|
||||
@@ -665,6 +765,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
QPair<int, QString> locationPair( deviceId, rpath );
|
||||
//debug() << "in urlId with url = " << url << " and uid = " << uid;
|
||||
//debug() << "checking locationPair " << locationPair;
|
||||
+/*
|
||||
if( m_urlsHashByLocation.contains( locationPair ) )
|
||||
{
|
||||
QStringList values;
|
||||
@@ -674,6 +775,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
values << "zero";
|
||||
//debug() << "m_urlsHashByLocation contains it! It is " << values;
|
||||
}
|
||||
+*/
|
||||
QStringList currUrlIdValues;
|
||||
if( m_urlsHashByUid.contains( uid ) && m_urlsHashByUid[uid] != 0 )
|
||||
currUrlIdValues = *m_urlsHashByUid[uid];
|
||||
@@ -717,6 +819,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
//debug() << "m_urlsHashByUid contains this UID, updating deviceId and path";
|
||||
QStringList *list = m_urlsHashByUid[uid];
|
||||
//debug() << "list from UID hash is " << list << " with values " << *list;
|
||||
+ QPair<int, QString> oldLocationPair( list->at( 1 ).toInt(), list->at( 2 ) );
|
||||
list->replace( 1, QString::number( deviceId ) );
|
||||
list->replace( 2, rpath );
|
||||
list->replace( 3, QString::number( dirId ) );
|
||||
@@ -737,6 +840,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
delete oldList;
|
||||
}
|
||||
m_urlsHashByLocation[locationPair] = list;
|
||||
+ m_urlsHashByLocation.remove( oldLocationPair );
|
||||
}
|
||||
m_permanentTablesUrlUpdates.insert( uid, url );
|
||||
m_changedUrls.insert( uid, QPair<QString, QString>( MountPointManager::instance()->getAbsolutePath( currUrlIdValues[1].toInt(), currUrlIdValues[2] ), url ) );
|
||||
@@ -751,6 +855,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
{
|
||||
QStringList *list = m_urlsHashByLocation[locationPair];
|
||||
//debug() << "Replacing hash " << list->at( 4 ) << " with " << uid;
|
||||
+ QString oldId = list->at( 4 );
|
||||
list->replace( 4, uid );
|
||||
if( m_urlsHashByUid.contains( uid )
|
||||
&& m_urlsHashByUid[uid] != 0
|
||||
@@ -762,6 +867,7 @@ ScanResultProcessor::urlId( const QStrin
|
||||
delete oldList;
|
||||
}
|
||||
m_urlsHashByUid[uid] = list;
|
||||
+ m_urlsHashByUid.remove( oldId );
|
||||
}
|
||||
m_permanentTablesUidUpdates.insert( url, uid );
|
||||
m_changedUids.insert( currUrlIdValues[4], uid );
|
||||
@@ -855,7 +961,8 @@ ScanResultProcessor::directoryId( const
|
||||
int
|
||||
ScanResultProcessor::checkExistingAlbums( const QString &album )
|
||||
{
|
||||
-// DEBUG_BLOCK
|
||||
+ //DEBUG_BLOCK
|
||||
+ //debug() << "looking for album " << album;
|
||||
// "Unknown" albums shouldn't be handled as compilations
|
||||
if( album.isEmpty() )
|
||||
return 0;
|
||||
@@ -865,7 +972,10 @@ ScanResultProcessor::checkExistingAlbums
|
||||
//it's probably a compilation.
|
||||
//this handles A1 compilations that were automatically organized by Amarok
|
||||
if( !m_albumsHashByName.contains( album ) || m_albumsHashByName[album] == 0 )
|
||||
+ {
|
||||
+ //debug() << "hashByName doesn't contain album, or it's zero";
|
||||
return 0;
|
||||
+ }
|
||||
|
||||
QStringList trackIds;
|
||||
QLinkedList<QStringList*> *llist = m_albumsHashByName[album];
|
||||
@@ -915,8 +1025,10 @@ ScanResultProcessor::checkExistingAlbums
|
||||
}
|
||||
}
|
||||
|
||||
+ //debug() << "trackIds = " << trackIds;
|
||||
if( trackIds.isEmpty() )
|
||||
{
|
||||
+ //debug() << "trackIds empty, returning zero";
|
||||
return 0;
|
||||
}
|
||||
else
|
||||
@@ -933,6 +1045,7 @@ ScanResultProcessor::checkExistingAlbums
|
||||
list->replace( 3, compilationString );
|
||||
}
|
||||
}
|
||||
+ //debug() << "returning " << compilationId;
|
||||
return compilationId;
|
||||
}
|
||||
}
|
||||
@@ -1167,6 +1280,17 @@ ScanResultProcessor::copyHashesToTempTab
|
||||
foreach( blahType key, m_urlsHashByLocation.keys() )
|
||||
debug() << "Key: " << key << ", list: " << *m_urlsHashByLocation[key];
|
||||
debug() << "Next album num: " << m_nextAlbumNum;
|
||||
+
|
||||
+ foreach( int key, m_tracksHashById.keys() )
|
||||
+ debug() << "Key: " << key << ", list: " << *m_tracksHashById[key];
|
||||
+ foreach( int key, m_tracksHashByUrl.keys() )
|
||||
+ debug() << "Key: " << key << ", list: " << *m_tracksHashByUrl[key];
|
||||
+ foreach( int key, m_tracksHashByAlbum.keys() )
|
||||
+ {
|
||||
+ debug() << "Key: " << key;
|
||||
+ foreach( QStringList* item, *m_tracksHashByAlbum[key] )
|
||||
+ debug() << "list: " << item << " is " << *item;
|
||||
+ }
|
||||
*/
|
||||
|
||||
DEBUG_BLOCK
|
14
amarok/patches/patch-ac
Normal file
14
amarok/patches/patch-ac
Normal file
|
@ -0,0 +1,14 @@
|
|||
$NetBSD: patch-ac,v 1.7 2010/01/13 13:37:33 thomasklausner Exp $
|
||||
|
||||
post-2.2.2 patch from upstream
|
||||
|
||||
--- src/collection/sqlcollection/ScanResultProcessor.h.orig 2010-01-06 22:19:46.000000000 +0000
|
||||
+++ src/collection/sqlcollection/ScanResultProcessor.h
|
||||
@@ -94,6 +94,7 @@ class ScanResultProcessor : public QObje
|
||||
QMap<QString, int> m_directories;
|
||||
QMap<QString, QList< QPair< QString, QString > > > m_imageMap;
|
||||
|
||||
+ QSet<QString> m_uidsSeenThisScan;
|
||||
QHash<QString, uint> m_filesInDirs;
|
||||
|
||||
TrackUrls m_changedUids; //not really track urls
|
Loading…
Reference in a new issue