From 31f6db24024c40156dcdf67bc1476d0283bf97c4 Mon Sep 17 00:00:00 2001 From: Luc Schrijvers Date: Tue, 19 Aug 2025 14:50:06 +0200 Subject: dolphinview: use QString::slice with Qt > 6.8 QString::slice is preferable when available, as it does not allocate. Amends db92361e10f356ed0d1bf2dc7ea3453086ce876c --- src/views/dolphinview.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/views/dolphinview.cpp') diff --git a/src/views/dolphinview.cpp b/src/views/dolphinview.cpp index e81b3b121..1ed857851 100644 --- a/src/views/dolphinview.cpp +++ b/src/views/dolphinview.cpp @@ -2247,7 +2247,11 @@ void DolphinView::applyDynamicView() for (const auto &file : itemList) { ++checkedItems; +#if QT_VERSION >= QT_VERSION_CHECK(6, 8, 0) + const QString type = file.mimetype().slice(0, 5); +#else const QString type = file.mimetype().sliced(0, 5); +#endif if (type == "image" || type == "video") { ++imageAndVideoCount; -- cgit v1.3