diff options
author | Jason Barron <jbarron@trolltech.com> | 2009-08-06 06:38:11 (GMT) |
---|---|---|
committer | Jason Barron <jbarron@trolltech.com> | 2009-08-06 07:18:48 (GMT) |
commit | 55c4f15df0d482c7d3d6c889b9fc132ed0bdd12a (patch) | |
tree | 99c01d7a4e0941f415e9a48f51faac94787b6cb0 /src/gui/itemviews | |
parent | 57ceb11ecf95032418712a686418116cf2398e7a (diff) | |
parent | b008dfbd67176948f6fdf830dc99d23a538a6b9c (diff) | |
download | Qt-55c4f15df0d482c7d3d6c889b9fc132ed0bdd12a.zip Qt-55c4f15df0d482c7d3d6c889b9fc132ed0bdd12a.tar.gz Qt-55c4f15df0d482c7d3d6c889b9fc132ed0bdd12a.tar.bz2 |
Merge commit 'qt/master-stable'
Conflicts:
configure.exe
doc/src/classes/qnamespace.qdoc
examples/examples.pro
src/corelib/kernel/qcoreevent.cpp
src/corelib/kernel/qobject.cpp
src/gui/kernel/qapplication.cpp
src/gui/kernel/qstandardgestures.h
src/gui/kernel/qwidget.cpp
Diffstat (limited to 'src/gui/itemviews')
-rw-r--r-- | src/gui/itemviews/qabstractitemview.cpp | 1 | ||||
-rw-r--r-- | src/gui/itemviews/qitemdelegate.cpp | 7 | ||||
-rw-r--r-- | src/gui/itemviews/qstyleditemdelegate.cpp | 8 |
3 files changed, 3 insertions, 13 deletions
diff --git a/src/gui/itemviews/qabstractitemview.cpp b/src/gui/itemviews/qabstractitemview.cpp index afcb918..9ad9da7 100644 --- a/src/gui/itemviews/qabstractitemview.cpp +++ b/src/gui/itemviews/qabstractitemview.cpp @@ -961,6 +961,7 @@ void QAbstractItemView::reset() d->currentIndexSet = false; setState(NoState); setRootIndex(QModelIndex()); + d->selectionModel->reset(); } /*! diff --git a/src/gui/itemviews/qitemdelegate.cpp b/src/gui/itemviews/qitemdelegate.cpp index 2c3d127..82d75ba 100644 --- a/src/gui/itemviews/qitemdelegate.cpp +++ b/src/gui/itemviews/qitemdelegate.cpp @@ -1238,12 +1238,7 @@ bool QItemDelegate::eventFilter(QObject *object, QEvent *event) if (QDragManager::self() && QDragManager::self()->object != 0) return false; #endif - // Opening a modal dialog will start a new eventloop - // that will process the deleteLater event. - if (QApplication::activeModalWidget() - && !QApplication::activeModalWidget()->isAncestorOf(editor) - && qobject_cast<QDialog*>(QApplication::activeModalWidget())) - return false; + emit commitData(editor); emit closeEditor(editor, NoHint); } diff --git a/src/gui/itemviews/qstyleditemdelegate.cpp b/src/gui/itemviews/qstyleditemdelegate.cpp index 5730c86..f64a8ea 100644 --- a/src/gui/itemviews/qstyleditemdelegate.cpp +++ b/src/gui/itemviews/qstyleditemdelegate.cpp @@ -686,13 +686,7 @@ bool QStyledItemDelegate::eventFilter(QObject *object, QEvent *event) if (QDragManager::self() && QDragManager::self()->object != 0) return false; #endif - // Opening a modal dialog will start a new eventloop - // that will process the deleteLater event. - QWidget *activeModalWidget = QApplication::activeModalWidget(); - if (activeModalWidget - && !activeModalWidget->isAncestorOf(editor) - && qobject_cast<QDialog*>(activeModalWidget)) - return false; + emit commitData(editor); emit closeEditor(editor, NoHint); } |