[Qt5-feedback] Adding better data access method to QAbstractItemModel?
Thiago Macieira
thiago at kde.org
Mon Jul 11 15:32:27 CEST 2011
On Monday, 11 de July de 2011 15:12:48 André Pönitz wrote:
> On Monday 11 July 2011 14:43:41 ext Stephen Kelly wrote:
> > That means this is source compatible for the emitter but not the receiver,
> > ie,
> >
> > emit dataChanged(foo, bar);
> >
> > still works, but
> >
> > connect(model, SIGNAL(dataChanged(QMI,QMI)), SLOT(onDataChanged(QMI,QMI));
> >
> > Needs to be changed to at least:
> >
> > connect(model, SIGNAL(dataChanged(QMI,QMI,QSet<int>)),
> > SLOT(onDataChanged(QMI,QMI));
> >
> > The (source compatible) alternative would be to add a roleDataChanged
> > signal with the signature I proposed instead of changing dataChanged (and
> > possibly deprecating dataChanged).
> >
> > What are your thoughts? Are small source incompatibilities like that
> > acceptible?
>
> Having to touch all dataChanged() receivers looks quite intrusive.
Then don't. Keep source compatibility:
signals:
dataChanged(QModelIndex, QModelIndex, QSet<int> = QSet<int>());
--
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
PGP/GPG: 0x6EF45358; fingerprint:
E067 918B B660 DBD1 105C 966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
Url : http://lists.qt.nokia.com/pipermail/qt5-feedback/attachments/20110711/dcf9399d/attachment.bin
More information about the Qt5-feedback
mailing list