Hi Tobias, try what the Thomas wrote, if this still not working I think this is related with bug #657 "http://bugs.openbossa.org/show_bug.cgi?id=657", I have already fixed this on my branch and I'm working to get this merged today.
Thanks On Mon, Feb 7, 2011 at 11:57 AM, Thomas Perl <th.p...@gmail.com> wrote: > Hi Tobias, > > 2011/2/7 Tobias Quinn <tob...@tobiasquinn.com>: >> I have a class that is a inherits from a QAbstractListModel and I want >> to emit a dataChanged signal (to signal a QML ListView). I've tried the >> following: >> >> self.dataChanged.emit(1, 1) >> >> but I get the error >> >> TypeError: Unknown type used to emit a signal: QModelIndex >> >> Am I going about this the wrong way? > > You probably want to use: > > self.dataChanged.emit(QModelIndex(1, 1), QModelIndex(1, 1)) > > That said, if you are not using Qt 4.7.1, you might be affected by > that bug even if you don't get the TypeError later: > > http://bugreports.qt.nokia.com/browse/QTBUG-13664 > > If your QAbstractListModel data consists of QObjects that have > properties that get displayed in the QML ListView, you can also effect > a display update if you emit the notify signal for the properties that > you are displaying (on the objects directly without going through > QAbstractListModel's API). Depending on how many properties you have > and how difficult your delegates are, notifying changes for only some > properties might be more efficient than emitting a dataChanged signal. > > HTH. > Thomas > _______________________________________________ > PySide mailing list > PySide@lists.openbossa.org > http://lists.openbossa.org/listinfo/pyside > -- Renato Araujo Oliveira Filho Instituto Nokia de Tecnologia - INdT Mobile: +55 (81) 8704-2144 _______________________________________________ PySide mailing list PySide@lists.openbossa.org http://lists.openbossa.org/listinfo/pyside