update translation install path
This commit is contained in:
parent
5a7a5d2112
commit
1a74e9c1fe
@ -451,7 +451,7 @@ QTranslator *DevicePlugin::translator()
|
|||||||
bool DevicePlugin::setLocale(const QLocale &locale)
|
bool DevicePlugin::setLocale(const QLocale &locale)
|
||||||
{
|
{
|
||||||
// check if there are local translations
|
// check if there are local translations
|
||||||
if (m_translator->load(locale, m_metaData.value("id").toString(), "-", QDir(QCoreApplication::applicationDirPath() + "../../translations/").absolutePath(), ".qm")) {
|
if (m_translator->load(locale, m_metaData.value("id").toString(), "-", QDir(QCoreApplication::applicationDirPath() + "../../plugins/translations/").absolutePath(), ".qm")) {
|
||||||
qCDebug(dcDeviceManager()) << "* Load translation" << locale.name() << "for" << pluginName() << "from" << QDir(QCoreApplication::applicationDirPath() + "../../translations/").absolutePath();
|
qCDebug(dcDeviceManager()) << "* Load translation" << locale.name() << "for" << pluginName() << "from" << QDir(QCoreApplication::applicationDirPath() + "../../translations/").absolutePath();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -23,9 +23,10 @@ infofile.commands = $$top_srcdir/plugins/guh-generateplugininfo -j ${QMAKE_FILE_
|
|||||||
-o ${QMAKE_FILE_OUT} \
|
-o ${QMAKE_FILE_OUT} \
|
||||||
-b $$OUT_PWD \
|
-b $$OUT_PWD \
|
||||||
-t $$TRANSLATIONS; \
|
-t $$TRANSLATIONS; \
|
||||||
rsync -a "$$OUT_PWD"/translations/*.qm $$top_builddir/translations/;
|
rsync -a "$$OUT_PWD"/translations/*.qm $$top_builddir/plugins/translations/;
|
||||||
|
|
||||||
QMAKE_EXTRA_COMPILERS += infofile
|
QMAKE_EXTRA_COMPILERS += infofile
|
||||||
|
PRE_TARGETDEPS += compiler_infofile_make_all
|
||||||
|
|
||||||
# Install translation files
|
# Install translation files
|
||||||
translations.path = /usr/share/guh/translations
|
translations.path = /usr/share/guh/translations
|
||||||
|
|||||||
Reference in New Issue
Block a user