forked from qt-creator/qt-creator
Use less nullptr for empty flags
Change-Id: Ic4eafdc8f204a432a752a97593380609a408a7de Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -78,7 +78,7 @@ QVariant SourceFilesHandler::headerData(int section,
|
||||
Qt::ItemFlags SourceFilesHandler::flags(const QModelIndex &index) const
|
||||
{
|
||||
if (index.row() >= m_fullNames.size())
|
||||
return nullptr;
|
||||
return {};
|
||||
QFileInfo fi(m_fullNames.at(index.row()));
|
||||
return fi.isReadable() ? QAbstractItemModel::flags(index) : Qt::ItemFlags({});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user