Prevent assert due to some odd role in older qt versions.

This commit is contained in:
Juergen Spitzmueller 2019-05-14 14:05:46 +02:00
parent 6df593049c
commit 3da25187a9

View File

@ -66,6 +66,10 @@ bool GuiIdListModel::setData(QModelIndex const & index,
if (role == Qt::DecorationRole) if (role == Qt::DecorationRole)
// nothing to do // nothing to do
return true; return true;
if (role == Qt::UserRole - 1)
// This role is set by Qt <= 5.5 if setEditable()
// of the item is false
return true;
// If we assert here, it's because we're trying to set an // If we assert here, it's because we're trying to set an
// unrecognized role. // unrecognized role.
LATTEST(false); LATTEST(false);