summaryrefslogtreecommitdiffstats
path: root/src/designer/src/components/taskmenu/itemlisteditor.cpp
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2020-10-28 09:31:42 +0100
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2020-10-28 13:05:59 +0100
commit8256ff13a8aab1aed192bb19a08c7126ac9028ae (patch)
tree1c32ae839a49861ac569794a792c17f230bad0f1 /src/designer/src/components/taskmenu/itemlisteditor.cpp
parent53113619ebad588859dac886c89356cd0ea2efba (diff)
Qt Designer: Port away from deprecated QVariant::Type
Change-Id: Ie0f7364454047ca7c9715f8d48814d71334a3cde Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/designer/src/components/taskmenu/itemlisteditor.cpp')
-rw-r--r--src/designer/src/components/taskmenu/itemlisteditor.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/designer/src/components/taskmenu/itemlisteditor.cpp b/src/designer/src/components/taskmenu/itemlisteditor.cpp
index ffa793c17..7d8514bd3 100644
--- a/src/designer/src/components/taskmenu/itemlisteditor.cpp
+++ b/src/designer/src/components/taskmenu/itemlisteditor.cpp
@@ -412,7 +412,7 @@ void ItemListEditor::setItemData(int role, const QVariant &v)
|| role == Qt::FontRole)
reLayout = true;
QVariant newValue = v;
- if (role == Qt::FontRole && newValue.type() == QVariant::Font) {
+ if (role == Qt::FontRole && newValue.metaType().id() == QMetaType::QFont) {
QFont oldFont = ui.listWidget->font();
QFont newFont = qvariant_cast<QFont>(newValue).resolve(oldFont);
newValue = QVariant::fromValue(newFont);