Summary: | Do not store play count and score metadata in files | ||
---|---|---|---|
Product: | [Applications] amarok | Reporter: | Tristan Miller <psychonaut> |
Component: | Collections/Local | Assignee: | Amarok Developers <amarok-bugs-dist> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | CC: | alan.ezust, mitchell, ootync, ralf-engels, samuel.brack, stuffcorpse |
Priority: | NOR | ||
Version: | 2.4-GIT | ||
Target Milestone: | 2.4.0 | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 2.4.1 | |
Sentry Crash Report: | |||
Attachments: | proposed patch to exclude "rating" from statistics |
Description
Tristan Miller
2010-12-07 14:10:16 UTC
I don't agree but I still implemented a configuration option that allows you to switch storing of meta data in the file on and off. The default is off. This seems to be a duplicate of bug 259320 *** Bug 259320 has been marked as a duplicate of this bug. *** Confirmed by duplicate I would like the option to store only RATINGS but not playcount or score. I like that there is an option, it's just not fine grained enough yet. I don't want the file changed whenever I play it. I like the idea of holding playcount and score in the database only. I guess we should implement this after the next release. I only want to have bug fixes in right now. If you don't want to wait this long you can path it for yourself if you like. Look at shared/MetaTagLib.cpp and search for config. You should see the code preventing any statistics from being written. You can easily patch this to write whatever information you like. Created attachment 55118 [details]
proposed patch to exclude "rating" from statistics
this patch changes the definition of the "write statistics back to file" option so that it does not include "rating" but only the play-changing statistics.
Thank you for the patch, Alan, could you please submit it to http://git.reviewboard.kde.org? commit ff5644d7058b102b5ae850d1c1ab2096f95f5f1a branch master Author: Mark Kretschmann <kretschmann@kde.org> Date: Sun Jan 16 13:05:49 2011 +0100 Do not store track rating as tags in files. Patch by Alan Ezusti <alan.ezust@gmail.com>. BUG: 259117 diff --git a/ChangeLog b/ChangeLog index 57b2fce..9147c4e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -7,6 +7,8 @@ VERSION 2.4.1 FEATURES: CHANGES: + * Do not store track rating as tags in files. Patch by Alan Ezusti + <alan.ezust@gmail.com>. (BR 259117) * Added missing tooltip for animation settings. Patch by Bhargav Mangipudi <bhargav.1191@gmail.com>. (BR 248690) diff --git a/shared/MetaTagLib.cpp b/shared/MetaTagLib.cpp index 90e2483..c6ec676 100644 --- a/shared/MetaTagLib.cpp +++ b/shared/MetaTagLib.cpp @@ -948,7 +948,8 @@ replaceField( TagLib::FileRef fileref, const qint64 &field, const QVariant &valu tValue = Qt4QStringToTString( QString::number( value.toInt() ) ); } - if( field == Meta::valRating || field == Meta::valPlaycount ) //tName == "POPM" + // POPM gets its information from either Rating (if available) or playcount (if not) + if( field == Meta::valRating || field == Meta::valPlaycount ) { TagLib::ID3v2::PopularimeterFrame* popFrame = 0; if( !tag->frameListMap()[tName].isEmpty() ) @@ -1168,10 +1169,10 @@ Meta::Tag::writeTags( const QString &path, const FieldHash &changes ) foreach( const qint64 field, changes.keys() ) { #ifndef UTILITIES_BUILD - // depending on the configuration we might not want to write back statistics + + // Statistics and scores are updated whenever you play a track, so we have a separate option for that. if( !AmarokConfig::writeBackStatistics() && (field == Meta::valScore || - field == Meta::valRating || field == Meta::valFirstPlayed || field == Meta::valLastPlayed || field == Meta::valPlaycount) ) diff --git a/src/dialogs/CollectionSetup.cpp b/src/dialogs/CollectionSetup.cpp index 0e4839f..ad2562b 100644 --- a/src/dialogs/CollectionSetup.cpp +++ b/src/dialogs/CollectionSetup.cpp @@ -144,8 +144,8 @@ CollectionSetup::CollectionSetup( QWidget *parent ) m_recursive->setToolTip( i18n( "If selected, Amarok will read all subfolders." ) ); m_monitor->setToolTip( i18n( "If selected, folders will automatically get rescanned\nwhen the content is modified,\ne.g. when a new file was added." ) ); - m_writeBack->setToolTip( i18n( "Write meta data changes back to the original file.\nYou can also prevent writing back by write protecting the file.\nThis might be a good idea if you are currently\nsharing those files via the internet." ) ); - m_writeBackStatistics->setToolTip( i18n( "Write changed statistics (e.g. rating or playcount)\nback to the file." ) ); + m_writeBack->setToolTip( i18n( "Write meta data changes (including 'stars' rating) back to the original file.\nYou can also prevent writing back by write protecting the file.\nThis might be a good idea if you are currently\nsharing those files via the internet." ) ); + m_writeBackStatistics->setToolTip( i18n( "Write play-changing statistics (e.g. score, lastplayed, playcount)\nas tags back to the file." ) ); m_writeBackCover->setToolTip( i18n( "Write changed covers back to the file.\nThis will replace existing embedded covers." ) ); m_charset->setToolTip( i18n( "If selected, Amarok will use Mozilla's\nCharacter Set Detector to attempt to automatically guess the\ncharacter sets used in ID3 tags." ) ); I am not sure if people are going to like this. I had complaints about writing ratings to the file. On the other hand I think it's fair to always write back the rating as that is explicitly set by the user. the changelog entry is not correct for the patch. It is in fact quite confusing. Also my name is not Ezusti. The description should be something like this: Exclude "rating" from play-changing statistics for the option "store statistics to file". "rating" is now stored along with other metadata since it is not changed automatically when the track is played. Hi Alan, I guess Mark was no at his best form when committing the patch. If you want to make more changes you might want to think about using the kde review board. Make sure to use the git review board and not the svn. They are different! Thanks again for the patch. Ralf On 01/17/2011 06:28 PM, ext Alan Ezust wrote: > https://bugs.kde.org/show_bug.cgi?id=259117 > > > > > > --- Comment #11 from Alan Ezust<alan ezust gmail com> 2011-01-17 18:28:41 --- > the changelog entry is not correct for the patch. It is in fact quite > confusing. > Also my name is not Ezusti. > > The description should be something like this: > > Exclude "rating" from play-changing statistics for the option "store statistics > to file". "rating" is now stored along with other metadata since it is not > changed automatically when the track is played. > 'FIXED'? ehm, I see no new options in 'amarokrc' in 2.4.0
> I am not sure if people are going to like this.
+1: hidden options in a config file are not intuitive.
I believe that the separation of options 'writing-stats/writing-ratings' would be welcomed by most of the users who ever find this feature useful
|