From 8f9c3e28d955b2798bdf4c4b042b3f63cbf0bd30 Mon Sep 17 00:00:00 2001 From: Bret Curtis Date: Mon, 22 Jun 2020 13:48:35 +0200 Subject: [PATCH] Handle typo --- apps/opencs/view/world/enumdelegate.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/opencs/view/world/enumdelegate.cpp b/apps/opencs/view/world/enumdelegate.cpp index eb1d631056..8027cec623 100644 --- a/apps/opencs/view/world/enumdelegate.cpp +++ b/apps/opencs/view/world/enumdelegate.cpp @@ -108,7 +108,8 @@ void CSVWorld::EnumDelegate::paint (QPainter *painter, const QStyleOptionViewIte const QModelIndex& index) const { int valueIndex = getValueIndex(index); - if (valueIndex != - + if (valueIndex != -1) + { QStyleOptionViewItem itemOption(option); itemOption.text = mValues.at(valueIndex).second; QApplication::style()->drawControl(QStyle::CE_ItemViewItem, &itemOption, painter);