1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-24 03:35:38 +03:00

testing/cppcheck: new aport

This commit is contained in:
AmatCoder 2015-01-22 05:34:41 +00:00 committed by Natanael Copa
parent e0681cfa7d
commit fd81a5935e
3 changed files with 108 additions and 0 deletions

View file

@ -0,0 +1,21 @@
--- cppcheck-1.68-origin/gui/main.cpp
+++ cppcheck-1.68/gui/main.cpp
@@ -57,12 +57,18 @@
QSettings* settings = new QSettings("Cppcheck", "Cppcheck-GUI", &app);
// Set data dir..
+ if ((settings->value("DATADIR", QString()).toString()).isEmpty())
+ settings->setValue("DATADIR", "/usr/share/cppcheck");
+
foreach(const QString arg, app.arguments()) {
if (arg.startsWith("--data-dir=")) {
settings->setValue("DATADIR", arg.mid(11));
return 0;
}
}
+
+ if ((settings->value(SETTINGS_LANGUAGE, QString()).toString()).isEmpty())
+ settings->setValue(SETTINGS_LANGUAGE, "en");
TranslationHandler* th = new TranslationHandler(&app);
th->SetLanguage(settings->value(SETTINGS_LANGUAGE, th->SuggestLanguage()).toString());