19d3766
diff -up cppcheck-1.70/gui/CMakeLists.txt.translations cppcheck-1.70/gui/CMakeLists.txt
19d3766
--- cppcheck-1.70/gui/CMakeLists.txt.translations	2015-11-05 11:37:19.343945331 -0800
19d3766
+++ cppcheck-1.70/gui/CMakeLists.txt	2015-11-05 11:37:19.344945349 -0800
aec3384
@@ -26,7 +26,7 @@ if (BUILD_GUI)
aec3384
     add_executable(cppcheck-gui ${hdrs} ${srcs} ${uis_hdrs} ${resources} ${qms})
aec3384
 
aec3384
     install(TARGETS cppcheck-gui RUNTIME DESTINATION bin COMPONENT applications)
aec3384
-    install(FILES ${qms} DESTINATION bin COMPONENT applications)
19d3766
+    install(FILES ${qms} DESTINATION share/${PROJECT_NAME}/lang/ COMPONENT applications)
aec3384
 
aec3384
     set(CMAKE_AUTOMOC OFF)
aec3384
 
19d3766
diff -up cppcheck-1.70/gui/translationhandler.cpp.translations cppcheck-1.70/gui/translationhandler.cpp
19d3766
--- cppcheck-1.70/gui/translationhandler.cpp.translations	2015-09-04 11:04:31.000000000 -0700
19d3766
+++ cppcheck-1.70/gui/translationhandler.cpp	2015-11-05 11:38:34.991299374 -0800
19d3766
@@ -106,15 +106,7 @@ bool TranslationHandler::SetLanguage(con
19d3766
     if (datadir.isEmpty())
19d3766
         datadir = appPath;
19d3766
 
19d3766
-    QString translationFile;
19d3766
-    if (QFile::exists(datadir + "/lang/" + mTranslations[index].mFilename + ".qm"))
19d3766
-        translationFile = datadir + "/lang/" + mTranslations[index].mFilename + ".qm";
19d3766
-
19d3766
-    else if (QFile::exists(datadir + "/" + mTranslations[index].mFilename + ".qm"))
19d3766
-        translationFile = datadir + "/" + mTranslations[index].mFilename + ".qm";
19d3766
-
19d3766
-    else
19d3766
-        translationFile = appPath + "/" + mTranslations[index].mFilename + ".qm";
19d3766
+    QString translationFile("/usr/share/CppCheck/lang/" + mTranslations[index].mFilename + ".qm");
19d3766
 
19d3766
     if (!mTranslator->load(translationFile) && !failure) {
19d3766
         translationFile += ".qm";