From 7e020aab1391fbca6aab0bdf7d11085f5947ad76 Mon Sep 17 00:00:00 2001 From: Raoul Snyman Date: Thu, 2 Jan 2014 22:58:13 +0200 Subject: [PATCH] Fix bug #1265368 by responding to clicks on both the item and the header, rather than the selection changing, which caused a harmless traceback when controlled from the remote. Fixes: https://launchpad.net/bugs/1265368 --- openlp/core/ui/slidecontroller.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/openlp/core/ui/slidecontroller.py b/openlp/core/ui/slidecontroller.py index 831cdc1d0..03322ce1f 100644 --- a/openlp/core/ui/slidecontroller.py +++ b/openlp/core/ui/slidecontroller.py @@ -391,7 +391,9 @@ class SlideController(Controller): self._slideShortcutActivated) # Signals QtCore.QObject.connect(self.previewListWidget, - QtCore.SIGNAL(u'itemSelectionChanged()'), self.onSlideSelected) + QtCore.SIGNAL(u'clicked(QModelIndex)'), self.onSlideSelected) + QtCore.QObject.connect(self.previewListWidget.verticalHeader(), + QtCore.SIGNAL(u'sectionClicked(int)'), self.onSlideSelected) if self.isLive: QtCore.QObject.connect(Receiver.get_receiver(), QtCore.SIGNAL(u'slidecontroller_live_spin_delay'), @@ -1082,7 +1084,7 @@ class SlideController(Controller): else: Receiver.send_message(u'live_display_show') - def onSlideSelected(self): + def onSlideSelected(self, index): """ Slide selected in controller """