Fix clang C compilation
authorAnton Malmygin <antonc27@mail.ru>
Sun, 12 May 2019 17:00:01 +0200
changeset 14943 b3890f4311f7
parent 14942 7ced40e21b2c
child 14944 d6e21765912e
Fix clang C compilation
QTfrontend/util/KeyMap.cpp
--- a/QTfrontend/util/KeyMap.cpp	Sun May 12 16:56:28 2019 +0300
+++ b/QTfrontend/util/KeyMap.cpp	Sun May 12 17:00:01 2019 +0200
@@ -64,9 +64,9 @@
             keyname = "";
             continue;
         }
-        if (cell == 0 && currChar != "\"") {
+        if (cell == 0 && currChar != '\"') {
             scancode += currChar;
-        } else if (cell == 1 && currChar != "\"") {
+        } else if (cell == 1 && currChar != '\"') {
             keyname += currChar;
         }
         charInCell++;
@@ -87,7 +87,7 @@
 QString KeyMap::getKeynameFromScancode(int scancode)
 {
     if (mapOfKeynames.contains((SDL_Scancode) scancode))
-        if (mapOfKeynames[(SDL_Scancode) scancode] == SDL_SCANCODE_UNKNOWN)
+        if ((SDL_Scancode) scancode == SDL_SCANCODE_UNKNOWN)
             return QString("none");
         else
             return mapOfKeynames[(SDL_Scancode) scancode];