--- a/src/hbwidgets/itemviews/hbtreemodeliterator_p.cpp Fri Jun 11 13:58:22 2010 +0300
+++ b/src/hbwidgets/itemviews/hbtreemodeliterator_p.cpp Wed Jun 23 18:33:25 2010 +0300
@@ -97,7 +97,7 @@
\reimp
Returnes index of item, which is visible at pos ordinal under parent.
Indexes in collapsed parents are not taken into account.
- Very slow - need to interate throught whole model in worst case!
+ Very slow - need to interate through whole model in worst case!
*/
QModelIndex HbTreeModelIterator::index(int pos, const QModelIndex &parent) const
{
@@ -295,6 +295,8 @@
this, SLOT(columnsInserted(QModelIndex,int,int)));
connect(d->mModel, SIGNAL(columnsRemoved(QModelIndex,int,int)),
this, SLOT(columnsRemoved(QModelIndex,int,int)));
+ connect(d->mModel, SIGNAL(layoutChanged()),
+ this, SLOT(modelLayoutChanged()));
}
} else {
setRootIndex(rootIndex);
@@ -393,5 +395,11 @@
d->resetCache();
}
+void HbTreeModelIterator::modelLayoutChanged()
+{
+ Q_D(HbTreeModelIterator);
+ d->resetCache();
+}
+
#include "moc_hbtreemodeliterator_p.cpp"