From 9c21c0a2a1eda015a28d27f83f353efbb3d56ec1 Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Tue, 27 Aug 2024 12:53:38 +0200 Subject: [PATCH] Update mime database from Qt qtbase/8a1eb24de8ef063fc5d0c3f10a7324d95bbc8709 Misc: Fix qsizetype-related narrowing coversions Change-Id: I203c6d554d99c96ceddd7f38efc47123b8fc3154 Reviewed-by: Jarek Kobus --- src/libs/utils/mimetypes2/mimetype.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libs/utils/mimetypes2/mimetype.cpp b/src/libs/utils/mimetypes2/mimetype.cpp index 2ecce70969a..9b87dfb6740 100644 --- a/src/libs/utils/mimetypes2/mimetype.cpp +++ b/src/libs/utils/mimetypes2/mimetype.cpp @@ -241,7 +241,7 @@ QString MimeType::comment() const const QString comm = d->localeComments.value(lang); if (!comm.isEmpty()) return comm; - const int pos = lang.indexOf(u'_'); + const qsizetype pos = lang.indexOf(u'_'); if (pos != -1) { // "pt_BR" not found? try just "pt" const QString shortLang = lang.left(pos); @@ -280,7 +280,7 @@ QString MimeType::genericIconName() const // (i.e. "video-x-generic" in the previous example). const QString group = name(); QStringView groupRef(group); - const int slashindex = groupRef.indexOf(u'/'); + const qsizetype slashindex = groupRef.indexOf(u'/'); if (slashindex != -1) groupRef = groupRef.left(slashindex); return groupRef + "-x-generic"_L1; @@ -290,7 +290,7 @@ QString MimeType::genericIconName() const static QString make_default_icon_name_from_mimetype_name(QString iconName) { - const int slashindex = iconName.indexOf(u'/'); + const qsizetype slashindex = iconName.indexOf(u'/'); if (slashindex != -1) iconName[slashindex] = u'-'; return iconName;