From 3f374afaae93a7804ee367098719c8a178d906f8 Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Fri, 28 Dec 2012 15:34:54 +0100 Subject: [PATCH] Get the default flags from the direct-base, not the indirect. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit QStringListModel inherits QAbstractListModel. Change-Id: I942321b2e5949f54041e11089f4131a646618b9e Reviewed-by: Thorbjørn Lund Martsum Reviewed-by: Stephen Kelly --- src/corelib/itemmodels/qstringlistmodel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/corelib/itemmodels/qstringlistmodel.cpp b/src/corelib/itemmodels/qstringlistmodel.cpp index 641dfb28f9..f3da06775a 100644 --- a/src/corelib/itemmodels/qstringlistmodel.cpp +++ b/src/corelib/itemmodels/qstringlistmodel.cpp @@ -170,9 +170,9 @@ QVariant QStringListModel::data(const QModelIndex &index, int role) const Qt::ItemFlags QStringListModel::flags(const QModelIndex &index) const { if (!index.isValid()) - return QAbstractItemModel::flags(index) | Qt::ItemIsDropEnabled; + return QAbstractListModel::flags(index) | Qt::ItemIsDropEnabled; - return QAbstractItemModel::flags(index) | Qt::ItemIsEditable | Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled; + return QAbstractListModel::flags(index) | Qt::ItemIsEditable | Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled; } /*!