rhythmbox r6184 - in trunk: . plugins/lyrics/lyrics
- From: jmatthew svn gnome org
- To: svn-commits-list gnome org
- Subject: rhythmbox r6184 - in trunk: . plugins/lyrics/lyrics
- Date: Mon, 9 Mar 2009 09:43:51 +0000 (UTC)
Author: jmatthew
Date: Mon Mar 9 09:43:51 2009
New Revision: 6184
URL: http://svn.gnome.org/viewvc/rhythmbox?rev=6184&view=rev
Log:
2009-03-09 Jonathan Matthew <jonathan d14n org>
* plugins/lyrics/lyrics/__init__.py:
Use 'lyrics' under the user cache dir for the default lyrics cache
directory instead of ~/.lyrics. Fixes #533199.
Modified:
trunk/ChangeLog
trunk/plugins/lyrics/lyrics/__init__.py
Modified: trunk/plugins/lyrics/lyrics/__init__.py
==============================================================================
--- trunk/plugins/lyrics/lyrics/__init__.py (original)
+++ trunk/plugins/lyrics/lyrics/__init__.py Mon Mar 9 09:43:51 2009
@@ -94,17 +94,17 @@
def build_cache_path(artist, title):
folder = gconf.client_get_default().get_string(gconf_keys['folder'])
if folder is None:
- folder = "~/.lyrics"
+ folder = os.path.join(rb.user_cache_dir(), "lyrics")
lyrics_folder = os.path.expanduser (folder)
if not os.path.exists (lyrics_folder):
os.mkdir (lyrics_folder)
- artist_folder = lyrics_folder + '/' + artist[:128]
+ artist_folder = os.path.join(lyrics_folder, artist[:128])
if not os.path.exists (artist_folder):
os.mkdir (artist_folder)
- return artist_folder + '/' + title[:128] + '.lyric'
+ return os.path.join(artist_folder, title[:128] + '.lyric')
class LyricGrabber(object):
def __init__(self, db, entry):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]