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.

bzr-revno: 2186
Fixes: https://launchpad.net/bugs/1265368
This commit is contained in:
Raoul Snyman 2014-01-05 23:07:12 +02:00
commit 109030c2c2
1 changed files with 4 additions and 2 deletions

View File

@ -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
"""