diff --git a/autotests/test_builtin_effectloader.cpp b/autotests/test_builtin_effectloader.cpp index e30e830c81..deedce5beb 100644 --- a/autotests/test_builtin_effectloader.cpp +++ b/autotests/test_builtin_effectloader.cpp @@ -176,7 +176,7 @@ void TestBuiltInEffectLoader::testKnownEffects() KWin::BuiltInEffectLoader loader; QStringList result = loader.listOfKnownEffects(); QCOMPARE(result.size(), expectedEffects.size()); - qSort(result); + std::sort(result.begin(), result.end()); for (int i = 0; i < expectedEffects.size(); ++i) { QCOMPARE(result.at(i), expectedEffects.at(i)); } @@ -557,7 +557,7 @@ void TestBuiltInEffectLoader::testLoadAllEffects() QCOMPARE(list.size(), 2); loadedEffects << list.at(1).toString(); } - qSort(loadedEffects); + std::sort(loadedEffects.begin(), loadedEffects.end()); QCOMPARE(loadedEffects.at(0), QStringLiteral("kscreen")); QCOMPARE(loadedEffects.at(1), QStringLiteral("mouseclick")); } diff --git a/autotests/test_scripted_effectloader.cpp b/autotests/test_scripted_effectloader.cpp index 5cc23aef2a..185edf48f2 100644 --- a/autotests/test_scripted_effectloader.cpp +++ b/autotests/test_scripted_effectloader.cpp @@ -437,7 +437,7 @@ void TestScriptedEffectLoader::testLoadAllEffects() QCOMPARE(list.size(), 2); loadedEffects << list.at(1).toString(); } - qSort(loadedEffects); + std::sort(loadedEffects.begin(), loadedEffects.end()); QCOMPARE(loadedEffects.at(0), kwin4 + QStringLiteral("eyeonscreen")); QCOMPARE(loadedEffects.at(1), kwin4 + QStringLiteral("fade")); } diff --git a/effects/presentwindows/presentwindows.cpp b/effects/presentwindows/presentwindows.cpp index 31f19e8c0c..f9ee8e9895 100644 --- a/effects/presentwindows/presentwindows.cpp +++ b/effects/presentwindows/presentwindows.cpp @@ -1133,7 +1133,7 @@ void PresentWindowsEffect::calculateWindowTransformationsKompose(EffectWindowLis QRect availRect = effects->clientArea(ScreenArea, screen, effects->currentDesktop()); if (m_showPanel) // reserve space for the panel availRect = effects->clientArea(MaximizeArea, screen, effects->currentDesktop()); - qSort(windowlist); // The location of the windows should not depend on the stacking order + std::sort(windowlist.begin(), windowlist.end()); // The location of the windows should not depend on the stacking order // Following code is taken from Kompose 0.5.4, src/komposelayout.cpp @@ -1280,7 +1280,7 @@ void PresentWindowsEffect::calculateWindowTransformationsNatural(EffectWindowLis // As we are using pseudo-random movement (See "slot") we need to make sure the list // is always sorted the same way no matter which window is currently active. - qSort(windowlist); + std::sort(windowlist.begin(), windowlist.end()); QRect area = effects->clientArea(ScreenArea, screen, effects->currentDesktop()); if (m_showPanel) // reserve space for the panel diff --git a/kcmkwin/common/effectsmodel.cpp b/kcmkwin/common/effectsmodel.cpp index 26d07c687e..110c0cf41b 100644 --- a/kcmkwin/common/effectsmodel.cpp +++ b/kcmkwin/common/effectsmodel.cpp @@ -397,7 +397,7 @@ void EffectsModel::load(LoadOptions options) loadJavascriptEffects(kwinConfig); loadPluginEffects(kwinConfig, configs); - qSort(m_pendingEffects.begin(), m_pendingEffects.end(), + std::sort(m_pendingEffects.begin(), m_pendingEffects.end(), [](const EffectData &a, const EffectData &b) { if (a.category == b.category) { if (a.exclusiveGroup == b.exclusiveGroup) { diff --git a/kcmkwin/kwincompositing/compositing.cpp b/kcmkwin/kwincompositing/compositing.cpp index 102dfd18cb..f8bbd92263 100644 --- a/kcmkwin/kwincompositing/compositing.cpp +++ b/kcmkwin/kwincompositing/compositing.cpp @@ -389,7 +389,7 @@ void CompositingType::generateCompositing() it++; } - qSort(m_compositingList.begin(), m_compositingList.end(), [](const CompositingData &a, const CompositingData &b) { + std::sort(m_compositingList.begin(), m_compositingList.end(), [](const CompositingData &a, const CompositingData &b) { return a.type < b.type; }); endResetModel();