openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #00191
[Merge] lp:~raoul-snyman/openlp/songmaintenance into lp:openlp
Raoul Snyman has proposed merging lp:~raoul-snyman/openlp/songmaintenance into lp:openlp.
Requested reviews:
openlp.org Core (openlp-core)
--
https://code.launchpad.net/~raoul-snyman/openlp/songmaintenance/+merge/9555
Your team openlp.org Core is subscribed to branch lp:openlp.
=== modified file 'openlp/plugins/songs/forms/authorsform.py'
--- openlp/plugins/songs/forms/authorsform.py 2009-07-26 10:02:18 +0000
+++ openlp/plugins/songs/forms/authorsform.py 2009-07-26 13:51:32 +0000
@@ -18,7 +18,7 @@
"""
from PyQt4 import QtGui, QtCore
from openlp.core.lib import translate
-from authorsdialog import Ui_AuthorsDialog
+from openlp.plugins.songs.forms.authorsdialog import Ui_AuthorsDialog
class AuthorsForm(QtGui.QDialog, Ui_AuthorsDialog):
"""
@@ -67,21 +67,21 @@
self.autoDisplayName = on
def accept(self):
- if self.FirstNameEdit.text() == u'':
+ if not self.FirstNameEdit.text():
QtGui.QMessageBox.critical(self,
translate(u'AuthorsDialog', u'Error'),
translate(u'AuthorsDialog', u'You need to type in the first name of the author.'),
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
self.FirstNameEdit.setFocus()
return False
- elif self.LastNameEdit.text() == u'':
+ elif not self.LastNameEdit.text():
QtGui.QMessageBox.critical(self,
translate(u'AuthorsDialog', u'Error'),
translate(u'AuthorsDialog', u'You need to type in the last name of the author.'),
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
self.LastNameEdit.setFocus()
return False
- elif self.DisplayEdit.text() == u'':
+ elif not self.DisplayEdit.text():
if QtGui.QMessageBox.critical(self,
translate(u'AuthorsDialog', u'Error'),
translate(u'AuthorsDialog', u'You haven\'t set a display name for the author, would you like me to combine the first and last names for you?'),
=== modified file 'openlp/plugins/songs/forms/songbookform.py'
--- openlp/plugins/songs/forms/songbookform.py 2009-07-26 08:36:57 +0000
+++ openlp/plugins/songs/forms/songbookform.py 2009-07-26 13:51:32 +0000
@@ -19,7 +19,7 @@
from PyQt4 import QtGui, QtCore
from openlp.core.lib import translate
-from songbookdialog import Ui_SongBookDialog
+from openlp.plugins.songs.forms.songbookdialog import Ui_SongBookDialog
class SongBookForm(QtGui.QDialog, Ui_SongBookDialog):
"""
@@ -40,7 +40,7 @@
return QtGui.QDialog.exec_(self)
def accept(self):
- if self.NameEdit.text() == u'':
+ if not self.NameEdit.text():
QtGui.QMessageBox.critical(self,
translate(u'SongBookDialog', u'Error'),
translate(u'SongBookDialog', u'You need to type in a book name!'),
=== modified file 'openlp/plugins/songs/forms/songmaintenanceform.py'
--- openlp/plugins/songs/forms/songmaintenanceform.py 2009-07-24 22:13:40 +0000
+++ openlp/plugins/songs/forms/songmaintenanceform.py 2009-08-02 19:10:54 +0000
@@ -79,15 +79,15 @@
item_id = self._getCurrentItemId(list_widget)
if item_id != -1:
item = get_func(item_id)
- if QtGui.QMessageBox.warning(self, dlg_title, del_text,
- QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.No | QtGui.QMessageBox.Yes)
- ) == QtGui.QMessageBox.Yes:
- if item is not None and len(item.songs) == 0:
+ if item is not None and len(item.songs) == 0:
+ if QtGui.QMessageBox.warning(self, dlg_title, del_text,
+ QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.No | QtGui.QMessageBox.Yes)
+ ) == QtGui.QMessageBox.Yes:
del_func(item.id)
reset_func()
- else:
- QtGui.QMessageBox.critical(self, dlg_title, err_text,
- QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
+ else:
+ QtGui.QMessageBox.critical(self, dlg_title, err_text,
+ QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
else:
QtGui.QMessageBox.critical(self, dlg_title, sel_text,
QtGui.QMessageBox.StandardButtons(QtGui.QMessageBox.Ok))
=== modified file 'openlp/plugins/songs/forms/topicsform.py'
--- openlp/plugins/songs/forms/topicsform.py 2009-07-26 08:36:57 +0000
+++ openlp/plugins/songs/forms/topicsform.py 2009-07-26 13:51:32 +0000
@@ -18,7 +18,7 @@
"""
from PyQt4 import QtGui, QtCore
from openlp.core.lib import translate
-from topicsdialog import Ui_TopicsDialog
+from openlp.plugins.songs.forms.topicsdialog import Ui_TopicsDialog
class TopicsForm(QtGui.QDialog, Ui_TopicsDialog):
"""
@@ -38,7 +38,7 @@
return QtGui.QDialog.exec_(self)
def accept(self):
- if self.NameEdit.text() == u'':
+ if not self.NameEdit.text():
QtGui.QMessageBox.critical(self,
translate(u'SongBookDialog', u'Error'),
translate(u'SongBookDialog', u'You need to type in a topic name!'),
Follow ups