summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/windows/qwindowsmime.h
diff options
context:
space:
mode:
authorGabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>2015-10-26 15:28:36 +0100
committerGabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>2015-10-27 11:58:32 +0000
commit8b9346c7404287b4c546b49c23f24ccbef0f8b6e (patch)
treeb1d737f03fa1fadbea57518c5f14aa5b42c13dda /src/plugins/platforms/windows/qwindowsmime.h
parent29a7f5571cb3619898d8d05c09f7df4ece915aed (diff)
Item Views: Avoid reentrant call in updateEditorGeometries()
This may result in incrementing an invalid iterator after the iterator's container has changed. Also, for this to happen, the view needs to have an active editor. The reentrant call happens as follows in QTreeView, after the model adds new rows to the view: QTreeView::rowsInserted() QAbstractItemView::rowsInserted() QAbstractItemView::updateEditorGeometries() QTreeView::visualRect() QAbstractItemViewPrivate::executePostedLayout() QTreeView::doItemsLayout() QAbstractItemView::doItemsLayout() QTreeView::updateGeometries() QAbstractItemView::updateGeometries() QAbstractItemView::updateEditorGeometries() Other concrete item view classes may be prone to the same issue. The fix consists in relayouting the items if needed, which should trigger calling updateEditorGeometries() again. This doesn't invalidate previous optimizations regarding item relayouting since we only force relayouting when it'll be done by visualRect(). Change-Id: Id31507fdc8d9a84d50265298191d690d1a06792b Task-number: QTBUG-48968 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Diffstat (limited to 'src/plugins/platforms/windows/qwindowsmime.h')
0 files changed, 0 insertions, 0 deletions