mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-30 09:45:36 +00:00
Init style in Qt6-compatible way
This commit is contained in:
parent
0de635dcdc
commit
0b3ba26d86
1 changed files with 5 additions and 0 deletions
|
@ -22,7 +22,12 @@ int CSVWidget::CompleterPopup::sizeHintForRow(int row) const
|
|||
|
||||
ensurePolished();
|
||||
QModelIndex index = model()->index(row, modelColumn());
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||
QStyleOptionViewItem option;
|
||||
initViewItemOption(&option);
|
||||
#else
|
||||
QStyleOptionViewItem option = viewOptions();
|
||||
#endif
|
||||
QAbstractItemDelegate* delegate = itemDelegate(index);
|
||||
return delegate->sizeHint(option, index).height();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue