From 91cb5951a86b1ec2030bdfc977205da668121782 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Mon, 18 May 2009 20:18:49 +0200 Subject: [PATCH] 100l - fix some typos in last updates. --- nephilim/plugins/Filebrowser.py | 2 ++ nephilim/plugins/Library.py | 5 ++++- nephilim/winMain.py | 7 ------- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/nephilim/plugins/Filebrowser.py b/nephilim/plugins/Filebrowser.py index 72e4d66..0c0b0bf 100644 --- a/nephilim/plugins/Filebrowser.py +++ b/nephilim/plugins/Filebrowser.py @@ -41,6 +41,7 @@ class wgFilebrowser(QtGui.QWidget): model = None path = None plugin = None + logger = None class FileView(QtGui.QListView): "context menu" @@ -104,6 +105,7 @@ class wgFilebrowser(QtGui.QWidget): def __init__(self, plugin): QtGui.QWidget.__init__(self) self.plugin = plugin + self.logger = plugin.logger self.model = QtGui.QDirModel() self.model.setFilter(QtCore.QDir.AllDirs|QtCore.QDir.AllEntries) diff --git a/nephilim/plugins/Library.py b/nephilim/plugins/Library.py index 06e2a41..391c7a1 100644 --- a/nephilim/plugins/Library.py +++ b/nephilim/plugins/Library.py @@ -77,6 +77,7 @@ class LibraryWidget(QtGui.QWidget): modes = None settings = None plugin = None + logger = None class LibraryModel(QtGui.QStandardItemModel): def fill(self, songs, mode): @@ -127,6 +128,7 @@ class LibraryWidget(QtGui.QWidget): def __init__(self, plugin): QtGui.QWidget.__init__(self) self.plugin = plugin + self.logger = plugin.logger self.settings = QtCore.QSettings() self.settings.beginGroup(self.plugin.name()) @@ -156,7 +158,7 @@ class LibraryWidget(QtGui.QWidget): self.connect(self.plugin.mpclient(), QtCore.SIGNAL('connected'), self.fill_library) self.connect(self.plugin.mpclient(), QtCore.SIGNAL('disconnected'), self.fill_library) - self.connect(self.plugin.mpclient(), QtCore.SIGNAL('update_finished'), self.fill_library) + self.connect(self.plugin.mpclient(), QtCore.SIGNAL('db_updated'), self.fill_library) def refresh_modes(self): self.modes.clear() @@ -165,6 +167,7 @@ class LibraryWidget(QtGui.QWidget): self.modes.setCurrentIndex(self.settings.value('current_mode').toInt()[0]) def fill_library(self): + self.logger.info('Refreshing library.') self.library_model.fill(self.plugin.mpclient().library(), str(self.modes.currentText())) def filter_changed(self, text): diff --git a/nephilim/winMain.py b/nephilim/winMain.py index 2529d8c..1ea6213 100644 --- a/nephilim/winMain.py +++ b/nephilim/winMain.py @@ -118,8 +118,6 @@ class winMain(QtGui.QMainWindow): " add event handlers" self.connect(self.mpclient, QtCore.SIGNAL('connected'), self.onConnected) self.connect(self.mpclient, QtCore.SIGNAL('disconnected'), self.onDisconnect) - self.connect(self.mpclient, QtCore.SIGNAL('update_started'), self.onUpdateDBStart) - self.connect(self.mpclient, QtCore.SIGNAL('update_finished'), self.onUpdateDBFinish) self.connect(self.mpclient, QtCore.SIGNAL('song_changed'), self.on_song_change) self.connect(self.mpclient, QtCore.SIGNAL('state_changed'), self.update_state_messages) self.connect(self.mpclient, QtCore.SIGNAL('time_changed'), self.on_time_change) @@ -248,11 +246,6 @@ class winMain(QtGui.QMainWindow): self.enableAll(False) self.setStatus("You are disconnected. Choose File->Connect to reconnect!") - def onUpdateDBFinish(self): - self.setStatus('') - def onUpdateDBStart(self): - self.setStatus('Updating the database. Please wait ...') - def update_state_messages(self): song = self.mpclient.current_song() state = self.mpclient.status()['state'] -- 2.11.4.GIT