v31.1-roots.1 · Commit 1: [PATCH 01/17] build(roots): establish v31 portability foundation
src/qt/bitcoin.cpp
Before: src/qt/bitcoin.cpp · After: src/qt/bitcoin.cpp
File metadata
index 92c815fe70e563329044a050537b4a1d254417cc..6f8a34dadad7a23f55a92ae42b00ccf10a9d6c48 100644
Download original patch · Release notes
Diff rows 1–11 of 11. Line numbers refer to the original before/after files.
+ Added− RemovedUnmarked lines are context.
Scroll the code area horizontally to read long lines. The two line-number columns refer to before and after.
src/qt/bitcoin.cpp
CHANGED
|
@@ -129,7 +129,11 @@ static void initTranslations(QTranslator &qtTranslatorBase, QTranslator &qtTrans
|
|
|
129
129
|
// - First load the translator for the base language, without territory
|
|
130
130
|
// - Then load the more specific locale translator
|
|
131
131
|
|
|
132
|
+
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
|
132
133
|
const QString translation_path{QLibraryInfo::path(QLibraryInfo::TranslationsPath)};
|
|
134
|
+
#else
|
|
135
|
+
const QString translation_path{QLibraryInfo::location(QLibraryInfo::TranslationsPath)};
|
|
136
|
+
#endif
|
|
133
137
|
// Load e.g. qt_de.qm
|
|
134
138
|
if (qtTranslatorBase.load("qt_" + lang, translation_path)) {
|
|
135
139
|
QApplication::installTranslator(&qtTranslatorBase);
|