diff --git a/lib/Emulation.cpp b/lib/Emulation.cpp index 10efe44..5313c42 100644 --- a/lib/Emulation.cpp +++ b/lib/Emulation.cpp @@ -133,7 +133,7 @@ void Emulation::setScreen(int n) if (_currentScreen != old) { // tell all windows onto this emulation to switch to the newly active screen - for(ScreenWindow* window : const_cast&>(_windows)) + for(ScreenWindow* window : qAsConst(_windows)) window->setScreen(_currentScreen); } } diff --git a/lib/tools.cpp b/lib/tools.cpp index 6ba2168..a24ac86 100644 --- a/lib/tools.cpp +++ b/lib/tools.cpp @@ -85,7 +85,7 @@ const QStringList get_color_schemes_dirs() rval << (QCoreApplication::applicationDirPath() + QLatin1String("/../Resources/color-schemes/")); } #endif - for (const QString& custom_dir : const_cast(custom_color_schemes_dirs)) + for (const QString& custom_dir : qAsConst(custom_color_schemes_dirs)) { d.setPath(custom_dir); if (d.exists())