1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-24 00:45:52 +00:00

Update from 0.17.1 to 0.21.1

PR:		ports/96898
Submitted by:	Peter Johnson <johnson.peter@gmail.com>
Approved by:	ChangBom Yoon <changbom.yoon@gmail.com> (maintainer)
This commit is contained in:
Vasil Dimov 2006-06-18 09:33:47 +00:00
parent 313c6c2e9c
commit a7a976a5d6
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=165678
5 changed files with 174 additions and 120 deletions

View File

@ -6,65 +6,82 @@
# #
PORTNAME= quodlibet PORTNAME= quodlibet
PORTVERSION= 0.17.1 PORTVERSION= 0.21.1
PORTREVISION= 1
CATEGORIES= multimedia audio python gnome CATEGORIES= multimedia audio python gnome
MASTER_SITES= http://www.sacredchao.net/~piman/software/ MASTER_SITES= http://www.sacredchao.net/~piman/software/
MAINTAINER= changbom.yoon@gmail.com MAINTAINER= changbom.yoon@gmail.com
COMMENT= A GTK+-based audio player written in Python COMMENT= A GTK+-based audio player written in Python
BUILD_DEPENDS= ${PYTHON_SITELIBDIR}/gst/__init__.py:${PORTSDIR}/multimedia/py-gstreamer80 INITIAL_DEP= ${PYTHON_SITELIBDIR}/gst-0.10/gst/__init__.py:${PORTSDIR}/multimedia/py-gstreamer \
RUN_DEPENDS= ${PYTHON_SITELIBDIR}/gst/__init__.py:${PORTSDIR}/multimedia/py-gstreamer80 ${PYTHON_SITELIBDIR}/mutagen/__init__.py:${PORTSDIR}/audio/py-mutagen
BUILD_DEPENDS= ${INITIAL_DEP}
RUN_DEPENDS= ${INITIAL_DEP}
USE_PYTHON= 2.3+ USE_PYTHON= 2.3+
USE_GNOME= pygtk2 USE_GNOME= pygtk2
USE_GMAKE= yes USE_GMAKE= yes
USE_X_PREFIX= yes USE_X_PREFIX= yes
USE_GSTREAMER80= gconf USE_GSTREAMER= yes
USE_GSTREAMER+= gconf
MAN1= exfalso.1 quodlibet.1 MAN1= exfalso.1 quodlibet.1
# Supported formats: ogg vorbis mad flac remote QUODLIBET_FORMATS?= ogg vorbis mp3 flac musepack wavpack aac remote
QUODLIBET_FORMATS?= ogg vorbis mad flac remote
.for format in ${QUODLIBET_FORMATS} .for format in ${QUODLIBET_FORMATS}
WANT_QUODLIBET_${format:U}= yes WANT_QUODLIBET_${format:U}= yes
.endfor .endfor
.if defined(WANT_QUODLIBET_OGG) .if defined(WANT_QUODLIBET_OGG)
BUILD_DEPENDS+= ${PYTHON_SITELIBDIR}/ogg/_ogg.so:${PORTSDIR}/audio/py-ogg USE_GSTREAMER+= ogg
RUN_DEPENDS+= ${PYTHON_SITELIBDIR}/ogg/_ogg.so:${PORTSDIR}/audio/py-ogg
USE_GSTREAMER80+= ogg
.endif .endif
.if defined(WANT_QUODLIBET_VORBIS) .if defined(WANT_QUODLIBET_VORBIS)
BUILD_DEPENDS+= ${PYTHON_SITELIBDIR}/ogg/vorbis.so:${PORTSDIR}/audio/py-vorbis USE_GSTREAMER+= vorbis
RUN_DEPENDS+= ${PYTHON_SITELIBDIR}/ogg/vorbis.so:${PORTSDIR}/audio/py-vorbis
USE_GSTREAMER80+= vorbis
.endif .endif
.if defined(WANT_QUODLIBET_MAD) .if defined(WANT_QUODLIBET_MP3)
BUILD_DEPENDS+= ${PYTHON_SITELIBDIR}/madmodule.so:${PORTSDIR}/audio/py-mad USE_GSTREAMER+= mad
RUN_DEPNDS+= ${PYTHON_SITELIBDIR}/madmodule.so:${PORTSDIR}/audio/py-mad
USE_GSTREAMER80+= mad
.endif .endif
.if defined(WANT_QUODLIBET_FLAC) .if defined(WANT_QUODLIBET_FLAC)
USE_GSTREAMER80+= flac USE_GSTREAMER+= flac
.endif
.if defined(WANT_QUODLIBET_MUSEPACK) || defined(WANT_QUODLIBET_WAVPACK) \
|| defined(WANT_QUODLIBET_AAC)
CTYPES_DEP= ${PYTHON_SITELIBDIR}/ctypes/__init__.py:${PORTSDIR}/devel/py-ctypes
BUILD_DEPENDS+= ${CTYPES_DEP}
RUN_DEPENDS+= ${CTYPES_DEP}
.endif
.if defined(WANT_QUODLIBET_MUSEPACK)
USE_GSTREAMER+= musepack
.endif
.if defined(WANT_QUODLIBET_WAVPACK)
USE_GSTREAMER+= wavpack
.endif
.if defined(WANT_QUODLIBET_AAC)
LIB_DEPENDS+= mp4v2.0:${PORTSDIR}/multimedia/mpeg4ip-libmp4v2
USE_GSTREAMER+= faad
.endif .endif
.if defined(WANT_QUODLIBET_REMOTE) .if defined(WANT_QUODLIBET_REMOTE)
BUILD_DEPENDS+= ${PYTHON_SITELIBDIR}/feedparser.py:${PORTSDIR}/textproc/py-feedparser FEEDPARSER_DEP= ${PYTHON_SITELIBDIR}/feedparser.py:${PORTSDIR}/textproc/py-feedparser
RUN_DEPENDS+= ${PYTHON_SITELIBDIR}/feedparser.py:${PORTSDIR}/textproc/py-feedparser BUILD_DEPENDS+= ${FEEDPARSER_DEP}
USE_GSTREAMER80+= gnomevfs RUN_DEPENDS+= ${FEEDPARSER_DEP}
USE_GSTREAMER+= gnomevfs
.endif .endif
.if defined(WITH_EXTENSIONS) .if defined(WITH_EXTENSIONS)
BUILD_DEPENDS+= ${PYTHON_SITELIBDIR}/gtk-2.0/egg/__init__.py:${PORTSDIR}/x11-toolkits/py-gnome-extras EXTRAS_DEP= ${PYTHON_SITELIBDIR}/gtk-2.0/egg/__init__.py:${PORTSDIR}/x11-toolkits/py-gnome-extras
RUN_DEPENDS+= ${PYTHON_SITELIBDIR}/gtk-2.0/egg/__init__.py:${PORTSDIR}/x11-toolkits/py-gnome-extras BUILD_DEPENDS+= ${EXTRAS_DEP}
PLIST_SUB+= EXTENSIONS:="" RUN_DEPENDS+= ${EXTRAS_DEP}
PLIST_SUB+= EXTENSIONS=""
.else .else
PLIST_SUB+= EXTENSIONS:="@comment " PLIST_SUB+= EXTENSIONS="@comment "
.endif .endif
.if defined(PACKAGE_BUILDING) .if defined(PACKAGE_BUILDING)
@ -75,22 +92,20 @@ BUILD_DEPENDS+= Xvfb:${X_VFBSERVER_PORT} \
.include <bsd.port.pre.mk> .include <bsd.port.pre.mk>
.if ${OSVERSION} < 500000 .if ${OSVERSION} < 500000
IGNORE= is unsupported on FreeBSD 4.x IGNORE= is unsupported on FreeBSD 4.x
.endif .endif
.if ${ARCH} == amd64 || ${ARCH} == sparc64 || ${ARCH} == ia64 .if ${ARCH} == amd64 || ${ARCH} == sparc64 || ${ARCH} == ia64
BROKEN= "Does not configure" BROKEN= Does not configure
.endif .endif
do-configure: do-configure:
@${PYTHON_CMD} ${WRKSRC}/check.py @${PYTHON_CMD} ${WRKSRC}/check.py
do-build: do-build:
@cd ${WRKSRC}/po && ${GMAKE} po
.if defined(WITH_EXTENSIONS) .if defined(WITH_EXTENSIONS)
@cd ${WRKSRC}/po && ${GMAKE} po
@cd ${WRKSRC} && ${GMAKE} extensions @cd ${WRKSRC} && ${GMAKE} extensions
.else
@cd ${WRKSRC}/po && ${GMAKE} po
.endif .endif
pre-install: pre-install:
@ -98,7 +113,8 @@ pre-install:
@${MKDIR} ${PREFIX}/share/applications @${MKDIR} ${PREFIX}/share/applications
post-install: post-install:
@${MKDIR} ${PREFIX}/share/${PORTNAME}/plugins @${MKDIR} ${DATADIR}/plugins
@${INSTALL_DATA} ${FILESDIR}/qlscrobbler.py ${PREFIX}/share/${PORTNAME}/plugins @${MKDIR} ${DATADIR}/plugins/events
@${INSTALL_DATA} ${FILESDIR}/qlscrobbler.py ${DATADIR}/plugins/events
.include <bsd.port.post.mk> .include <bsd.port.post.mk>

View File

@ -1,3 +1,3 @@
MD5 (quodlibet-0.17.1.tar.gz) = 457e03c9aeed83077172185a06664c96 MD5 (quodlibet-0.21.1.tar.gz) = 39508a281244e5b9264d2f9692e5f498
SHA256 (quodlibet-0.17.1.tar.gz) = 4a2fda947933991bbdf0d338afbcb3a01f19b87f0418867086bf68ce4cda6011 SHA256 (quodlibet-0.21.1.tar.gz) = c093116a7b3846a937c37396f630dd8e5ea79654a38e322144b231ce685926d5
SIZE (quodlibet-0.17.1.tar.gz) = 434299 SIZE (quodlibet-0.21.1.tar.gz) = 498151

View File

@ -1,21 +0,0 @@
--- quodlibet.py.orig 2005-12-12 15:43:59.000000000 -0700
+++ quodlibet.py 2006-01-07 11:25:44.773179056 -0700
@@ -273,15 +273,15 @@
basedir = os.getcwd()
if basedir.endswith("/share/quodlibet"):
sys.path.append(basedir[:-15] + "lib/quodlibet")
- i18ndir = "/usr/share/locale"
+ i18ndir = "/usr/X11R6/share/locale"
import locale, gettext, util
try: locale.setlocale(locale.LC_ALL, '')
except: pass
- gettext.bindtextdomain("quodlibet")
+ gettext.bindtextdomain("quodlibet", i18ndir)
gettext.textdomain("quodlibet")
- util.gettext_install("quodlibet", unicode=True)
+ util.gettext_install("quodlibet", i18ndir, unicode=True)
util.ctypes_init()
from util import to

View File

@ -1,31 +1,37 @@
# QLScrobbler: an Audioscrobbler client plugin for Quod Libet. # QLScrobbler: an Audioscrobbler client plugin for Quod Libet.
# version 0.7 # version 0.8
# (C) 2005 by Joshua Kwan <joshk@triplehelix.org>, # (C) 2005 by Joshua Kwan <joshk@triplehelix.org>,
# Joe Wreschnig <piman@sacredchao.net> # Joe Wreschnig <piman@sacredchao.net>
# Licensed under GPLv2. See Quod Libet's COPYING for more information. # Licensed under GPLv2. See Quod Libet's COPYING for more information.
import random import random
import md5, urllib, urllib2, time, threading, os import md5, urllib, urllib2, time, threading, os
import player, config, const import player, config, const, widgets, parse
import gobject, gtk import gobject, gtk
from qltk import Message from qltk.msg import Message, WarningMessage
from qltk.entry import ValidatingEntry
from util import to from util import to
class QLScrobbler(object): from plugins.events import EventPlugin
class QLScrobbler(EventPlugin):
# session invariants # session invariants
PLUGIN_NAME = "QLScrobbler" PLUGIN_NAME = "QLScrobbler"
PLUGIN_DESC = "Audioscrobbler client for Quod Libet" PLUGIN_DESC = "Audioscrobbler client for Quod Libet"
PLUGIN_ICON = gtk.STOCK_CONNECT PLUGIN_ICON = gtk.STOCK_CONNECT
PLUGIN_VERSION = "0.7" PLUGIN_VERSION = "0.8.1"
CLIENT = "qlb" CLIENT = "qlb"
PROTOCOL_VERSION = "1.1" PROTOCOL_VERSION = "1.1"
DUMP = os.path.join(const.DIR, "scrobbler_cache") try: DUMP = os.path.join(const.USERDIR, "scrobbler_cache")
except AttributeError:
DUMP = os.path.join(const.DIR, "scrobbler_cache")
# things that could change # things that could change
username = "" username = ""
password = "" password = ""
pwhash = "" pwhash = ""
exclude = ""
timeout_id = -1 timeout_id = -1
submission_tid = -1 submission_tid = -1
@ -42,7 +48,8 @@ class QLScrobbler(object):
already_submitted = False already_submitted = False
locked = False locked = False
flushing = False flushing = False
disabled = False __enabled = False
offline = False
# we need to store this because not all events get the song # we need to store this because not all events get the song
song = None song = None
@ -55,6 +62,9 @@ class QLScrobbler(object):
dump = open(self.DUMP, 'r') dump = open(self.DUMP, 'r')
self.read_dump(dump) self.read_dump(dump)
except: pass except: pass
# Read configuration
self.read_config()
# Set up exit hook to dump queue # Set up exit hook to dump queue
gtk.quit_add(0, self.dump_queue) gtk.quit_add(0, self.dump_queue)
@ -68,7 +78,7 @@ class QLScrobbler(object):
key = "" key = ""
value = "" value = ""
line = line.rstrip() line = line.rstrip("\n")
try: (key, value) = line.split(" = ", 1) try: (key, value) = line.split(" = ", 1)
except: except:
if line == "-": if line == "-":
@ -113,6 +123,7 @@ class QLScrobbler(object):
for item in self.queue: for item in self.queue:
for key in item: for key in item:
dump.write("%s = %s\n" % (key, item[key])) dump.write("%s = %s\n" % (key, item[key]))
dump.write("-\n")
dump.close() dump.close()
@ -151,6 +162,12 @@ class QLScrobbler(object):
elif 'title' not in song: return elif 'title' not in song: return
elif "artist" not in song: elif "artist" not in song:
if ("composer" not in song) and ("performer" not in song): return if ("composer" not in song) and ("performer" not in song): return
# Check to see if this song is not something we'd like to submit
# e.g. "Hit Me Baby One More Time"
if self.exclude != "" and parse.Query(self.exclude).search(song):
print to("Not submitting: %s - %s" % (song["artist"], song["title"]))
return
self.song = song self.song = song
if player.playlist.paused == False: if player.playlist.paused == False:
@ -185,7 +202,7 @@ class QLScrobbler(object):
if self.timeout_id == -2: # change delta based on current progress if self.timeout_id == -2: # change delta based on current progress
# assumption is that self.already_submitted == 0, therefore # assumption is that self.already_submitted == 0, therefore
# delay - progress > 0 # delay - progress > 0
progress = int(player.playlist.info.time[0] / 1000) progress = int(player.playlist.get_position() / 1000)
delay -= progress delay -= progress
self.timeout_id = gobject.timeout_add(delay * 1000, self.submit_song) self.timeout_id = gobject.timeout_add(delay * 1000, self.submit_song)
@ -197,10 +214,16 @@ class QLScrobbler(object):
username = config.get("plugins", "scrobbler_username") username = config.get("plugins", "scrobbler_username")
password = config.get("plugins", "scrobbler_password") password = config.get("plugins", "scrobbler_password")
except: except:
if self.need_config == False: if (self.need_config == False and
self.quick_info("Please visit the Preferences window to set QLScrobbler up. Until then, songs will not be submitted.") getattr(self, 'PMEnFlag', False)):
self.quick_dialog("Please visit the Preferences window to set QLScrobbler up. Until then, songs will not be submitted.", gtk.MESSAGE_INFO)
self.need_config = True self.need_config = True
return return
try: self.offline = (config.get("plugins", "scrobbler_offline") == "true")
except: pass
try: self.exclude = config.get("plugins", "scrobbler_exclude")
except: pass
self.username = username self.username = username
@ -211,22 +234,14 @@ class QLScrobbler(object):
def __destroy_cb(self, dialog, response_id): def __destroy_cb(self, dialog, response_id):
dialog.destroy() dialog.destroy()
def quick_error_helper(self, str):
dialog = Message(gtk.MESSAGE_ERROR, None, "QLScrobbler", str)
dialog.connect('response', self.__destroy_cb)
dialog.show()
def quick_error(self, str):
gobject.idle_add(self.quick_error_helper, str)
def quick_info_helper(self, str): def quick_dialog_helper(self, type, str):
dialog = Message(gtk.MESSAGE_INFO, widgets.widgets.main, "QLScrobbler", str).run() dialog = Message(gtk.MESSAGE_INFO, widgets.main, "QLScrobbler", str)
dialog.connect('response', self.__destroy_cb) dialog.connect('response', self.__destroy_cb)
dialog.show() dialog.show()
def quick_info(self, str): def quick_dialog(self, str, type):
gobject.idle_add(self.quick_info_helper, str) gobject.idle_add(self.quick_dialog_helper, type, str)
def clear_waiting(self): def clear_waiting(self):
self.waiting = False self.waiting = False
@ -253,7 +268,7 @@ class QLScrobbler(object):
if status == "UPTODATE" or status.startswith("UPDATE"): if status == "UPTODATE" or status.startswith("UPDATE"):
if status.startswith("UPDATE"): if status.startswith("UPDATE"):
self.quick_info("A new plugin is available at %s! Please download it, or your Audioscrobbler stats may not be updated, and this message will be displayed every session." % status.split()[1]) self.quick_dialog("A new plugin is available at %s! Please download it, or your Audioscrobbler stats may not be updated, and this message will be displayed every session." % status.split()[1], gtk.MESSAGE_INFO)
self.need_update = True self.need_update = True
# Scan for submit URL and challenge. # Scan for submit URL and challenge.
@ -271,7 +286,7 @@ class QLScrobbler(object):
self.challenge_sent = True self.challenge_sent = True
elif status == "BADUSER": elif status == "BADUSER":
self.quick_error("Authentication failed: invalid username %s or bad password." % self.username) self.quick_dialog("Authentication failed: invalid username %s or bad password." % self.username, gtk.MESSAGE_ERROR)
self.broken = True self.broken = True
@ -289,23 +304,29 @@ class QLScrobbler(object):
bg.setDaemon(True) bg.setDaemon(True)
bg.start() bg.start()
def enabled(self):
self.__enabled = True
def disabled(self):
self.__enabled = False
def submit_song_helper(self): def submit_song_helper(self):
enabled = getattr(self, 'PMEnFlag', False) if self.__enabled:
if enabled and self.disabled:
print "Plugin re-enabled - accepting new songs." print "Plugin re-enabled - accepting new songs."
self.disabled = False
if self.submission_tid != -1: if self.submission_tid != -1:
gobject.source_remove(self.submission_tid); gobject.source_remove(self.submission_tid);
self.submission_tid = -1 self.submission_tid = -1
elif not enabled and not self.disabled: #if we've already printed else:
print "Plugin disabled - not accepting any new songs." print "Plugin disabled - not accepting any new songs."
self.disabled = True
if len(self.queue) > 0: if len(self.queue) > 0:
self.submission_tid = gobject.timeout_add(120 * 1000, self.submit_song_helper) self.submission_tid = gobject.timeout_add(120 * 1000, self.submit_song_helper)
print "Attempts will continue to submit the last %d songs." % len(self.queue) print "Attempts will continue to submit the last %d songs." % len(self.queue)
if self.already_submitted == True or self.broken == True: return if self.already_submitted == True or self.broken == True: return
# Scope.
store = {}
if self.flushing == False: if self.flushing == False:
stamp = time.strftime("%Y-%m-%d %H:%M:%S", time.gmtime()) stamp = time.strftime("%Y-%m-%d %H:%M:%S", time.gmtime())
@ -327,14 +348,16 @@ class QLScrobbler(object):
store["artist"] = performer[:performer.rindex("(")].strip() store["artist"] = performer[:performer.rindex("(")].strip()
else: else:
store["artist"] = performer store["artist"] = performer
elif "musicbrainz_trackid" in self.song: if "musicbrainz_trackid" in self.song:
store["mbid"] = self.song["musicbrainz_trackid"] store["mbid"] = self.song["musicbrainz_trackid"]
self.queue.append(store) self.queue.append(store)
else: self.flushing = False else: self.flushing = False
if self.locked == True: # Just note to stdout if either of these are true..
# another instance running, let it deal with this # locked means another instance if s_s_h is dealing with sending.
if self.offline or self.locked:
print to("Queuing: %s - %s" % (store["artist"], store["title"]))
return return
self.locked = True self.locked = True
@ -360,7 +383,7 @@ class QLScrobbler(object):
} }
# Flush the cache # Flush the cache
for i in range(len(self.queue)): for i in range(min(len(self.queue), 10)):
print to("Sending song: %s - %s" % (self.queue[i]['artist'], self.queue[i]['title'])) print to("Sending song: %s - %s" % (self.queue[i]['artist'], self.queue[i]['title']))
data["a[%d]" % i] = self.queue[i]['artist'].encode('utf-8') data["a[%d]" % i] = self.queue[i]['artist'].encode('utf-8')
data["t[%d]" % i] = self.queue[i]['title'].encode('utf-8') data["t[%d]" % i] = self.queue[i]['title'].encode('utf-8')
@ -400,16 +423,16 @@ class QLScrobbler(object):
self.challenge_sent = False self.challenge_sent = False
self.send_handshake() self.send_handshake()
if self.challenge_sent == False: if self.challenge_sent == False:
self.quick_error("Your Audioscrobbler login data is incorrect, so you must re-enter it before any songs will be submitted.\n\nThis message will not be shown again.") self.quick_dialog("Your Audioscrobbler login data is incorrect, so you must re-enter it before any songs will be submitted.\n\nThis message will not be shown again.", gtk.MESSAGE_ERROR)
self.broken = True self.broken = True
elif status == "OK": elif status == "OK":
self.queue = [] self.queue = self.queue[10:]
elif status.startswith("FAILED"): elif status.startswith("FAILED"):
if status.startswith("FAILED Plugin bug"): if status.startswith("FAILED Plugin bug"):
print "Plugin bug!? Ridiculous! Dumping queue contents." print "Plugin bug!? Ridiculous! Dumping queue contents."
for item in self.queue: for item in self.queue:
for key in item: for key in item:
print "%s = %s" % (key, item[key]) print to("%s = %s" % (key, item[key]))
# possibly handle other specific cases here for debugging later # possibly handle other specific cases here for debugging later
else: else:
print "Unknown response from server: %s" % status print "Unknown response from server: %s" % status
@ -424,7 +447,7 @@ class QLScrobbler(object):
gobject.timeout_add(interval_secs * 1000, self.clear_waiting) gobject.timeout_add(interval_secs * 1000, self.clear_waiting)
print "Server says to wait for %d seconds." % interval_secs print "Server says to wait for %d seconds." % interval_secs
if self.disabled and len(self.queue) == 0 and self.submission_tid != -1: if not self.__enabled and len(self.queue) == 0 and self.submission_tid != -1:
print "All songs submitted, disabling retries." print "All songs submitted, disabling retries."
gobject.source_remove(self.submission_tid) gobject.source_remove(self.submission_tid)
self.submission_tid = -1 self.submission_tid = -1
@ -433,8 +456,16 @@ class QLScrobbler(object):
self.locked = False self.locked = False
def PluginPreferences(self, parent): def PluginPreferences(self, parent):
def toggled(widget):
if widget.get_active():
config.set("plugins", "scrobbler_offline", "true")
self.offline = True
else:
config.set("plugins", "scrobbler_offline", "false")
self.offline = False
def changed(entry, key): def changed(entry, key):
# having two functions is unnecessary.. # having a function for each entry is unnecessary..
config.set("plugins", "scrobbler_" + key, entry.get_text()) config.set("plugins", "scrobbler_" + key, entry.get_text())
def destroyed(*args): def destroyed(*args):
@ -448,35 +479,55 @@ class QLScrobbler(object):
except: except:
return return
try: self.exclude = config.get("plugins", "scrobbler_exclude")
except: pass
if self.username != newu or self.password != newp: if self.username != newu or self.password != newp:
self.broken = False self.broken = False
table = gtk.Table(3, 2) table = gtk.Table(6, 3)
table.set_col_spacings(3) table.set_col_spacings(3)
lt = gtk.Label(_("Please enter your Audioscrobbler username and password.")) lt = gtk.Label(_("Please enter your Audioscrobbler\nusername and password."))
lt.set_size_request(260, -1)
lu = gtk.Label(_("Username:")) lu = gtk.Label(_("Username:"))
lp = gtk.Label(_("Password:")) lp = gtk.Label(_("Password:"))
for l in [lt, lu, lp]: lv = gtk.Label(_("Exclude filter:"))
lvd = gtk.Label(_("Songs matching this filter will\nnot be sent to Audioscrobbler.\n"))
off = gtk.CheckButton(_("Offline mode (don't submit anything)"))
ve = ValidatingEntry(parse.Query.is_valid_color)
for l in [lt, lu, lp, lv, lvd]:
l.set_line_wrap(True) l.set_line_wrap(True)
l.set_alignment(0.0, 0.5) l.set_alignment(0.0, 0.5)
table.attach(lt, 0, 2, 0, 1, xoptions=gtk.FILL) table.attach(lt, 0, 2, 0, 1, xoptions=gtk.FILL | gtk.SHRINK)
table.attach(lu, 0, 1, 1, 2, xoptions=gtk.FILL) table.attach(lu, 0, 1, 1, 2, xoptions=gtk.FILL | gtk.SHRINK)
table.attach(lp, 0, 1, 2, 3, xoptions=gtk.FILL) table.attach(lp, 0, 1, 2, 3, xoptions=gtk.FILL | gtk.SHRINK)
table.attach(lv, 0, 1, 3, 4, xoptions=gtk.FILL | gtk.SHRINK)
userent = gtk.Entry() userent = gtk.Entry()
pwent = gtk.Entry() pwent = gtk.Entry()
pwent.set_visibility(False) pwent.set_visibility(False)
pwent.set_invisible_char('*') pwent.set_invisible_char('*')
table.set_border_width(6) table.set_border_width(6)
table.attach(ve, 1, 2, 3, 4, xoptions=gtk.FILL | gtk.SHRINK)
table.attach(lvd, 0, 2, 4, 5, xoptions=gtk.FILL | gtk.SHRINK)
table.attach(off, 0, 2, 5, 7, xoptions=gtk.FILL | gtk.SHRINK)
try: userent.set_text(config.get("plugins", "scrobbler_username")) try: userent.set_text(config.get("plugins", "scrobbler_username"))
except: pass except: pass
try: pwent.set_text(config.get("plugins", "scrobbler_password")) try: pwent.set_text(config.get("plugins", "scrobbler_password"))
except: pass except: pass
try:
if config.get("plugins", "scrobbler_offline") == "true":
off.set_active(True)
except: pass
try: ve.set_text(config.get("plugins", "scrobbler_exclude"))
except: pass
table.attach(userent, 1, 2, 1, 2) table.attach(userent, 1, 2, 1, 2, xoptions=gtk.FILL | gtk.SHRINK)
table.attach(pwent, 1, 2, 2, 3) table.attach(pwent, 1, 2, 2, 3, xoptions=gtk.FILL | gtk.SHRINK)
pwent.connect('changed', changed, 'password') pwent.connect('changed', changed, 'password')
userent.connect('changed', changed, 'username') userent.connect('changed', changed, 'username')
ve.connect('changed', changed, 'exclude')
table.connect('destroy', destroyed) table.connect('destroy', destroyed)
off.connect('toggled', toggled)
return table return table

View File

@ -1,7 +1,7 @@
bin/exfalso bin/exfalso
bin/quodlibet bin/quodlibet
%%EXTENSIONS:%%lib/quodlibet/_mmkeys.so %%EXTENSIONS%%lib/quodlibet/_mmkeys.so
%%EXTENSIONS:%%lib/quodlibet/_trayicon.so %%EXTENSIONS%%lib/quodlibet/_trayicon.so
share/applications/exfalso.desktop share/applications/exfalso.desktop
share/applications/quodlibet.desktop share/applications/quodlibet.desktop
share/locale/bg/LC_MESSAGES/quodlibet.mo share/locale/bg/LC_MESSAGES/quodlibet.mo
@ -13,12 +13,17 @@ share/locale/fi/LC_MESSAGES/quodlibet.mo
share/locale/fr/LC_MESSAGES/quodlibet.mo share/locale/fr/LC_MESSAGES/quodlibet.mo
share/locale/gl/LC_MESSAGES/quodlibet.mo share/locale/gl/LC_MESSAGES/quodlibet.mo
share/locale/he/LC_MESSAGES/quodlibet.mo share/locale/he/LC_MESSAGES/quodlibet.mo
share/locale/hu/LC_MESSAGES/quodlibet.mo
share/locale/it/LC_MESSAGES/quodlibet.mo share/locale/it/LC_MESSAGES/quodlibet.mo
share/locale/ko/LC_MESSAGES/quodlibet.mo share/locale/ko/LC_MESSAGES/quodlibet.mo
share/locale/lt/LC_MESSAGES/quodlibet.mo
share/locale/nb/LC_MESSAGES/quodlibet.mo
share/locale/nl/LC_MESSAGES/quodlibet.mo share/locale/nl/LC_MESSAGES/quodlibet.mo
share/locale/pl/LC_MESSAGES/quodlibet.mo share/locale/pl/LC_MESSAGES/quodlibet.mo
share/locale/pt/LC_MESSAGES/quodlibet.mo share/locale/pt/LC_MESSAGES/quodlibet.mo
share/locale/ru/LC_MESSAGES/quodlibet.mo share/locale/ru/LC_MESSAGES/quodlibet.mo
share/locale/sv/LC_MESSAGES/quodlibet.mo
share/locale/zh_CN/LC_MESSAGES/quodlibet.mo
share/pixmaps/exfalso.png share/pixmaps/exfalso.png
share/pixmaps/quodlibet.png share/pixmaps/quodlibet.png
share/quodlibet/browsers/__init__.py share/quodlibet/browsers/__init__.py
@ -39,7 +44,6 @@ share/quodlibet/formats/__init__.py
share/quodlibet/formats/_apev2.py share/quodlibet/formats/_apev2.py
share/quodlibet/formats/_audio.py share/quodlibet/formats/_audio.py
share/quodlibet/formats/_vorbis.py share/quodlibet/formats/_vorbis.py
share/quodlibet/formats/ape.py
share/quodlibet/formats/flac.py share/quodlibet/formats/flac.py
share/quodlibet/formats/mod.py share/quodlibet/formats/mod.py
share/quodlibet/formats/mp3.py share/quodlibet/formats/mp3.py
@ -47,27 +51,23 @@ share/quodlibet/formats/mp4.py
share/quodlibet/formats/mpc.py share/quodlibet/formats/mpc.py
share/quodlibet/formats/oggvorbis.py share/quodlibet/formats/oggvorbis.py
share/quodlibet/formats/remote.py share/quodlibet/formats/remote.py
share/quodlibet/formats/wav.py
share/quodlibet/formats/wavpack.py share/quodlibet/formats/wavpack.py
share/quodlibet/library.py share/quodlibet/library.py
share/quodlibet/massagers.py
share/quodlibet/mutagen/__init__.py
share/quodlibet/mutagen/_constants.py
share/quodlibet/mutagen/_vorbis.py
share/quodlibet/mutagen/apev2.py
share/quodlibet/mutagen/flac.py
share/quodlibet/mutagen/id3.py
share/quodlibet/parse/__init__.py share/quodlibet/parse/__init__.py
share/quodlibet/parse/_match.py share/quodlibet/parse/_match.py
share/quodlibet/parse/_pattern.py share/quodlibet/parse/_pattern.py
share/quodlibet/parse/_query.py share/quodlibet/parse/_query.py
share/quodlibet/player.py share/quodlibet/player.py
share/quodlibet/plugins/__init__.py share/quodlibet/plugins/__init__.py
share/quodlibet/plugins/_manager.py
share/quodlibet/plugins/editing.py share/quodlibet/plugins/editing.py
share/quodlibet/plugins/qlscrobbler.py share/quodlibet/plugins/events.py
share/quodlibet/plugins/events/qlscrobbler.py
share/quodlibet/plugins/songsmenu.py
share/quodlibet/qltk/__init__.py share/quodlibet/qltk/__init__.py
share/quodlibet/qltk/_editpane.py share/quodlibet/qltk/_editpane.py
share/quodlibet/qltk/about.py share/quodlibet/qltk/about.py
share/quodlibet/qltk/bookmarks.py
share/quodlibet/qltk/browser.py share/quodlibet/qltk/browser.py
share/quodlibet/qltk/cbes.py share/quodlibet/qltk/cbes.py
share/quodlibet/qltk/ccb.py share/quodlibet/qltk/ccb.py
@ -96,8 +96,11 @@ share/quodlibet/qltk/queue.py
share/quodlibet/qltk/quodlibet.py share/quodlibet/qltk/quodlibet.py
share/quodlibet/qltk/remote.py share/quodlibet/qltk/remote.py
share/quodlibet/qltk/renamefiles.py share/quodlibet/qltk/renamefiles.py
share/quodlibet/qltk/session.py
share/quodlibet/qltk/sliderbutton.py share/quodlibet/qltk/sliderbutton.py
share/quodlibet/qltk/songlist.py share/quodlibet/qltk/songlist.py
share/quodlibet/qltk/songsmenu.py
share/quodlibet/qltk/tagscombobox.py
share/quodlibet/qltk/tagsfrompath.py share/quodlibet/qltk/tagsfrompath.py
share/quodlibet/qltk/textedit.py share/quodlibet/qltk/textedit.py
share/quodlibet/qltk/tracknumbers.py share/quodlibet/qltk/tracknumbers.py
@ -114,9 +117,14 @@ share/quodlibet/rhythmbox-volume-medium.png
share/quodlibet/rhythmbox-volume-min.png share/quodlibet/rhythmbox-volume-min.png
share/quodlibet/rhythmbox-volume-zero.png share/quodlibet/rhythmbox-volume-zero.png
share/quodlibet/stock.py share/quodlibet/stock.py
share/quodlibet/util.py share/quodlibet/util/__init__.py
share/quodlibet/util/i18n.py
share/quodlibet/util/massagers.py
share/quodlibet/util/uri.py
share/quodlibet/widgets.py share/quodlibet/widgets.py
@dirrmtry share/applications @dirrmtry share/applications
@exec mkdir -p %D/share/quodlibet/plugins/events
@dirrm share/quodlibet/plugins/events
@exec mkdir -p %D/share/quodlibet/plugins @exec mkdir -p %D/share/quodlibet/plugins
@dirrm share/quodlibet/plugins @dirrm share/quodlibet/plugins
@exec mkdir -p %D/lib/quodlibet @exec mkdir -p %D/lib/quodlibet
@ -125,11 +133,11 @@ share/quodlibet/widgets.py
@dirrm share/quodlibet/browsers @dirrm share/quodlibet/browsers
@exec mkdir -p %D/share/quodlibet/formats @exec mkdir -p %D/share/quodlibet/formats
@dirrm share/quodlibet/formats @dirrm share/quodlibet/formats
@exec mkdir -p %D/share/quodlibet/mutagen
@dirrm share/quodlibet/mutagen
@exec mkdir -p %D/share/quodlibet/parse @exec mkdir -p %D/share/quodlibet/parse
@dirrm share/quodlibet/parse @dirrm share/quodlibet/parse
@exec mkdir -p %D/share/quodlibet/qltk @exec mkdir -p %D/share/quodlibet/qltk
@dirrm share/quodlibet/qltk @dirrm share/quodlibet/qltk
@exec mkdir -p %D/share/quodlibet/util
@dirrm share/quodlibet/util
@exec mkdir -p %D/share/quodlibet @exec mkdir -p %D/share/quodlibet
@dirrm share/quodlibet @dirrm share/quodlibet