]> git.pld-linux.org Git - packages/cppcheck.git/blame - cppcheck-translations.patch
- updated to 1.71
[packages/cppcheck.git] / cppcheck-translations.patch
CommitLineData
4338603d
JR
1diff -up cppcheck-1.70/gui/CMakeLists.txt.translations cppcheck-1.70/gui/CMakeLists.txt
2--- cppcheck-1.70/gui/CMakeLists.txt.translations 2015-11-05 11:37:19.343945331 -0800
3+++ cppcheck-1.70/gui/CMakeLists.txt 2015-11-05 11:37:19.344945349 -0800
4@@ -26,7 +26,7 @@ if (BUILD_GUI)
5 add_executable(cppcheck-gui ${hdrs} ${srcs} ${uis_hdrs} ${resources} ${qms})
6
7 install(TARGETS cppcheck-gui RUNTIME DESTINATION bin COMPONENT applications)
8- install(FILES ${qms} DESTINATION bin COMPONENT applications)
9+ install(FILES ${qms} DESTINATION share/${PROJECT_NAME}/lang/ COMPONENT applications)
10
11 set(CMAKE_AUTOMOC OFF)
12
13diff -up cppcheck-1.70/gui/translationhandler.cpp.translations cppcheck-1.70/gui/translationhandler.cpp
14--- cppcheck-1.70/gui/translationhandler.cpp.translations 2015-09-04 11:04:31.000000000 -0700
15+++ cppcheck-1.70/gui/translationhandler.cpp 2015-11-05 11:38:34.991299374 -0800
16@@ -106,15 +106,7 @@ bool TranslationHandler::SetLanguage(con
17 if (datadir.isEmpty())
18 datadir = appPath;
19
20- QString translationFile;
21- if (QFile::exists(datadir + "/lang/" + mTranslations[index].mFilename + ".qm"))
22- translationFile = datadir + "/lang/" + mTranslations[index].mFilename + ".qm";
23-
24- else if (QFile::exists(datadir + "/" + mTranslations[index].mFilename + ".qm"))
25- translationFile = datadir + "/" + mTranslations[index].mFilename + ".qm";
26-
27- else
28- translationFile = appPath + "/" + mTranslations[index].mFilename + ".qm";
29+ QString translationFile("/usr/share/CppCheck/lang/" + mTranslations[index].mFilename + ".qm");
30
31 if (!mTranslator->load(translationFile) && !failure) {
32 translationFile += ".qm";
This page took 0.076774 seconds and 4 git commands to generate.