[Qt-qml] emit data on a QAbstracListModel does not update the QML ListView.

Martin Jones martin.jones at nokia.com
Wed Sep 15 01:44:06 CEST 2010


On Wed, 15 Sep 2010 05:26:58 am ext Bartosh Wroblevksy wrote:
> Hi Steve,
> 
> I forgot to ask about this:
> > > 2) I have trouble seeing how in this case, moving rows and changing
> > > data is not equivalent. In fact,unless my morning coffee was not
> > > caffeinated. If I write
> > > 
> > > m_elements[1] ="x"; emit dataChanged(index(1,0), index(1,0));
> > > Should I not expect to see the QML listview change?
> > 
> > Yes, you are right. Indeed that is another bug. What you are doing
> > WorksFromMe, but I don't have a plugin for the model like you do, but I
> > create the QDeclarativeMainView in an application and use
> > setContextProperty(myModel). Maybe if loaded through a plugin qml doesn't
> > handle that signal somehow?
> > 
> > It's worth another bug report.
> 
> Did we actually confirm that it is a bug and that the signal does not get
> handled when loaded through a plugin? Is there a bug number for this? Do
> you want me to log one?

It is extremely unlikely that loading through a plugin changes the behavior.  
There was a bug if you set a root index:

http://bugreports.qt.nokia.com/browse/QTBUG-13038



-- 
Martin



More information about the Qt-qml mailing list