PDA

View Full Version : QAbstractTableModel::data not being called...



steg90
5th June 2007, 08:59
Hi,

I've updated to Qt 4.3 from 4.2.3 and now find that my custom table model data function is not being called, whether this is just coincidence I don't know?

I am calling emit layoutChanged() which use to call the data(const QModelIndex &index, int role) function. I'm not sure now why this has stopped working:confused:

Any advice is much appreciated,

Regards,
Steve

steg90
5th June 2007, 09:52
I got this working by adding the following lines :



int row = theApp->m_dcb.GetSignalList()->count();
beginInsertRows(QModelIndex(), row, row );
endInsertRows();



Previously I didn't have to do this, the layoutChanged signal had worked fine, it is only since moving to Qt 4.3 from 4.2.3 this has happened?

Regards,
Steve