Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
Please login to access the resource
openSUSE:Leap:15.2:Staging:N
extra-cmake-modules
bundle-lang.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File bundle-lang.patch of Package extra-cmake-modules
From d68190a86ac823d64355a33cfd78bd9e8ffd2785 Mon Sep 17 00:00:00 2001 From: Luca Beltrame <lbeltrame@kde.org> Date: Wed, 26 Sep 2018 22:50:24 +0200 Subject: [PATCH] openSUSE's bundle-lang packages install the translations in /usr/share/locale-bundle/ to not conflict with the standard -lang packages. So look there too if a translation was not found in /usr/share/locale/. --- modules/ECMQmLoader.cpp.in | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) Index: extra-cmake-modules-5.56.0git.20200226T180944~040504d/modules/ECMQmLoader.cpp.in =================================================================== --- extra-cmake-modules-5.56.0git.20200226T180944~040504d.orig/modules/ECMQmLoader.cpp.in 2020-02-27 07:10:58.979815190 +0100 +++ extra-cmake-modules-5.56.0git.20200226T180944~040504d/modules/ECMQmLoader.cpp.in 2020-02-27 07:13:15.674038108 +0100 @@ -44,15 +44,19 @@ QString subPath = QStringLiteral("locale/") + localeDirName + QStringLiteral("/LC_MESSAGES/@QM_LOADER_CATALOG_NAME@.qm"); #if defined(Q_OS_ANDROID) - const QString fullPath = QStringLiteral("assets:/share/") + subPath; + QString fullPath = QStringLiteral("assets:/share/") + subPath; if (!QFile::exists(fullPath)) { return false; } #else - const QString fullPath = QStandardPaths::locate(QStandardPaths::GenericDataLocation, subPath); + QString fullPath = QStandardPaths::locate(QStandardPaths::GenericDataLocation, subPath); + if (fullPath.isEmpty()) { + subPath = QStringLiteral("locale-bundle/") + localeDirName + QStringLiteral("/LC_MESSAGES/@QM_LOADER_CATALOG_NAME@.qm"); + fullPath = QStandardPaths::locate(QStandardPaths::GenericDataLocation, subPath); if (fullPath.isEmpty()) { return false; } + } #endif QTranslator *translator = new QTranslator(QCoreApplication::instance()); if (!translator->load(fullPath)) {
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor