openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #09451
[Merge] lp:~smpettit/openlp/bug-789102 into lp:openlp
Stevan Pettit has proposed merging lp:~smpettit/openlp/bug-789102 into lp:openlp.
Requested reviews:
OpenLP Core (openlp-core)
For more details, see:
https://code.launchpad.net/~smpettit/openlp/bug-789102/+merge/62793
Fixed bug-789102. Made changes to song and custom mediaitems and edit forms to not autoselect mediamanager items when doing item edits from preview or slidecontroller.
--
https://code.launchpad.net/~smpettit/openlp/bug-789102/+merge/62793
Your team OpenLP Core is requested to review the proposed merge of lp:~smpettit/openlp/bug-789102 into lp:openlp.
=== modified file 'openlp/core/lib/mediamanageritem.py'
--- openlp/core/lib/mediamanageritem.py 2011-05-27 09:34:14 +0000
+++ openlp/core/lib/mediamanageritem.py 2011-05-29 13:15:54 +0000
@@ -455,7 +455,8 @@
"""
if QtCore.QSettings().value(u'advanced/single click preview',
QtCore.QVariant(False)).toBool() and self.quickPreviewAllowed \
- and self.listView.selectedIndexes():
+ and self.listView.selectedIndexes() \
+ and self.auto_select_id == -1:
self.onPreviewClick(True)
def onPreviewClick(self, keepFocus=False):
=== modified file 'openlp/plugins/custom/forms/editcustomform.py'
--- openlp/plugins/custom/forms/editcustomform.py 2011-05-27 09:34:14 +0000
+++ openlp/plugins/custom/forms/editcustomform.py 2011-05-29 13:15:54 +0000
@@ -137,7 +137,8 @@
self.customSlide.credits = unicode(self.creditEdit.text())
self.customSlide.theme_name = unicode(self.themeComboBox.currentText())
success = self.manager.save_object(self.customSlide)
- self.parent.auto_select_id = self.customSlide.id
+ if self.parent.new:
+ self.parent.auto_select_id = self.customSlide.id
return success
def onUpButtonClicked(self):
=== modified file 'openlp/plugins/custom/lib/mediaitem.py'
--- openlp/plugins/custom/lib/mediaitem.py 2011-05-27 09:34:14 +0000
+++ openlp/plugins/custom/lib/mediaitem.py 2011-05-29 13:15:54 +0000
@@ -66,6 +66,7 @@
# which Custom is required.
self.remoteCustom = -1
self.manager = parent.manager
+ self.new = False
def addEndHeaderBar(self):
self.addToolbarSeparator()
@@ -156,9 +157,11 @@
self.auto_select_id = -1
def onNewClick(self):
+ self.new = True
self.edit_custom_form.loadCustom(0)
self.edit_custom_form.exec_()
self.initialise()
+ self.new = False
def onRemoteEditClear(self):
self.remoteTriggered = None
=== modified file 'openlp/plugins/songs/forms/editsongform.py'
--- openlp/plugins/songs/forms/editsongform.py 2011-05-27 09:34:14 +0000
+++ openlp/plugins/songs/forms/editsongform.py 2011-05-29 13:15:54 +0000
@@ -755,7 +755,8 @@
self.song.topics.append(self.manager.get_object(Topic, topicId))
clean_song(self.manager, self.song)
self.manager.save_object(self.song)
- self.parent.auto_select_id = self.song.id
+ if self.parent.new:
+ self.parent.auto_select_id = self.song.id
def _processLyrics(self):
"""
=== modified file 'openlp/plugins/songs/lib/mediaitem.py'
--- openlp/plugins/songs/lib/mediaitem.py 2011-05-27 09:34:14 +0000
+++ openlp/plugins/songs/lib/mediaitem.py 2011-05-29 13:15:54 +0000
@@ -74,6 +74,7 @@
self.editItem = None
self.quickPreviewAllowed = True
self.hasSearch = True
+ self.new = False
def addEndHeaderBar(self):
self.addToolbarSeparator()
@@ -296,8 +297,10 @@
def onNewClick(self):
log.debug(u'onNewClick')
+ self.new = True
self.edit_song_form.newSong()
self.edit_song_form.exec_()
+ self.new = False
def onSongMaintenanceClick(self):
self.song_maintenance_form.exec_()
Follow ups