diff options
author | Christian Kandeler <christian.kandeler@digia.com> | 2012-09-20 10:31:34 +0200 |
---|---|---|
committer | hjk <qthjk@ovi.com> | 2012-09-20 11:11:45 +0200 |
commit | 938612c35e82bec69868e1bf6490c1b331085d82 (patch) | |
tree | 695b915720cc20a6524e0ea2f28a54a9fb24af7f /src/plugins/android/androidsettingswidget.cpp | |
parent | 1b3d637c1ba12cb9b8880000d05d1c864f81ce86 (diff) | |
download | qt-creator-938612c35e82bec69868e1bf6490c1b331085d82.tar.gz |
Do not use QAbstractItemModel::reset().
Change-Id: Ie49bdf576a6d3543aef6df133b27c8827775c935
Rationale:
a) It is conceptually cleaner to do the changes to the model
in between calls to beginResetModel() and endResetModel,
respectively.
b) The function is deprecated in Qt 5, for exactly that reason.
Reviewed-by: hjk <qthjk@ovi.com>
Diffstat (limited to 'src/plugins/android/androidsettingswidget.cpp')
-rw-r--r-- | src/plugins/android/androidsettingswidget.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/android/androidsettingswidget.cpp b/src/plugins/android/androidsettingswidget.cpp index ae8d2b7283..12366ff9d2 100644 --- a/src/plugins/android/androidsettingswidget.cpp +++ b/src/plugins/android/androidsettingswidget.cpp @@ -51,8 +51,9 @@ namespace Internal { void AvdModel::setAvdList(const QVector<AndroidDeviceInfo> &list) { + beginResetModel(); m_list = list; - reset(); + endResetModel(); } QString AvdModel::avdName(const QModelIndex &index) |