Repair the Windows Build
authorKevin Ottens <kevin.ottens@nextcloud.com>
Mon, 30 Nov 2020 11:47:17 +0000 (12:47 +0100)
committerKevin Ottens <kevin.ottens@nextcloud.com>
Tue, 15 Dec 2020 09:59:21 +0000 (10:59 +0100)
We now enforce the use of QStringLiteral and friends in some places,
but that feel through the cracks for some of the Windows specific code.

Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
src/common/utility_win.cpp
src/csync/csync_exclude.cpp

index 7c2f68ee76e11b9a990946fca4a96e9da7d3ea3f..5aec8db5182df577d274e024455a3787d757361d 100644 (file)
@@ -102,8 +102,8 @@ void setLaunchOnStartup_private(const QString &appName, const QString &guiName,
 static inline bool hasDarkSystray_private()
 {
     if(Utility::registryGetKeyValue(    HKEY_CURRENT_USER,
-                                        R"(Software\Microsoft\Windows\CurrentVersion\Themes\Personalize)",
-                                        "SystemUsesLightTheme" ) == 1) {
+                                        QStringLiteral(R"(Software\Microsoft\Windows\CurrentVersion\Themes\Personalize)"),
+                                        QStringLiteral("SystemUsesLightTheme") ) == 1) {
         return false;
     }
     else {
index 8d342b45d8c840fd9da172c99ed921e3c1cab79c..f531c2d15f9f127b03555c355f0e7aa5eaa684c1 100644 (file)
@@ -264,7 +264,7 @@ void ExcludedFiles::addManualExclude(const QString &expr)
 void ExcludedFiles::addManualExclude(const QString &expr, const QString &basePath)
 {
 #if defined(Q_OS_WIN)
-    Q_ASSERT(basePath.size() >= 2 && basePath.at(1) == ':');
+    Q_ASSERT(basePath.size() >= 2 && basePath.at(1) == QLatin1Char(':'));
 #else
     Q_ASSERT(basePath.startsWith(QLatin1Char('/')));
 #endif