Use correct event handlers

This commit is contained in:
Arjan Schrijver 2013-02-17 19:33:39 +01:00
parent cc9464ea74
commit c1ba98ee0f

View File

@ -157,12 +157,9 @@ class ImageMediaItem(MediaManagerItem):
# Create the context menu and add all actions from the listView. # Create the context menu and add all actions from the listView.
self.menu = QtGui.QMenu() self.menu = QtGui.QMenu()
self.menu.addActions(self.listView.actions()) self.menu.addActions(self.listView.actions())
QtCore.QObject.connect(self.listView, QtCore.SIGNAL(u'doubleClicked(QModelIndex)'), self.listView.doubleClicked.connect(self.onDoubleClicked)
self.onDoubleClicked) self.listView.itemSelectionChanged.connect(self.onSelectionChange)
QtCore.QObject.connect(self.listView, QtCore.SIGNAL(u'itemSelectionChanged()'), self.listView.customContextMenuRequested.connect(self.contextMenu)
self.onSelectionChange)
QtCore.QObject.connect(self.listView, QtCore.SIGNAL(u'customContextMenuRequested(QPoint)'),
self.contextMenu)
self.listView.addAction(self.replaceAction) self.listView.addAction(self.replaceAction)
def addStartHeaderBar(self): def addStartHeaderBar(self):