Hi,
Am Monday, 13. October 2008 schrieb Bastian Venthur:
> how can I catch a selectionChanged signal from a tableView? I tried:
>
> QtCore.QObject.connect( self.tableView,
> QtCore.SIGNAL('selectionChanged(const QItemSelection&,
> const QItemSelection&)'),
> self.selection_changed)
try with a QItemSelectionModel:
fileSelectionModel = QtGui.QItemSelectionModel(itemModel, tableView)
tableView.setSelectionModel(fileSelectionModel)
self.connect(fileSelectionModel, SIGNAL(
"currentChanged(const QModelIndex &, const QModelIndex &)"),
self.cellSelected)
self.connect(fileSelectionModel, SIGNAL(
"selectionChanged(const QItemSelection &, const QItemSelection &)"),
self.updateSelection)
Hope that is what you were looking for.
Chris
_______________________________________________
PyQt mailing list [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt