From 2e7c58b987c2d8d5435a23a1950697033fb24b7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chusslove=20Illich=20=28=D0=A7=D0=B0=D1=81=D0=BB=D0=B0?= =?UTF-8?q?=D0=B2=20=D0=98=D0=BB=D0=B8=D1=9B=29?= Date: Mon, 5 Aug 2013 11:19:11 +0200 Subject: [PATCH] Temporary fix for translations location binding. insertCatalog calls will not be used either way. --- src/plasma/abstractrunner.cpp | 10 +++++----- src/plasma/dataengine.cpp | 10 +++++----- src/plasma/private/applet_p.cpp | 10 +++++----- .../qml/plasmoid/declarativeappletscript.cpp | 3 --- 4 files changed, 15 insertions(+), 18 deletions(-) diff --git a/src/plasma/abstractrunner.cpp b/src/plasma/abstractrunner.cpp index b0e2eee33..3fe228ec3 100644 --- a/src/plasma/abstractrunner.cpp +++ b/src/plasma/abstractrunner.cpp @@ -447,11 +447,11 @@ void AbstractRunnerPrivate::setupScriptSupport() // << ", main script is" << package->filePath("mainscript"); #endif - const QString translationsPath = package->filePath("translations"); - if (!translationsPath.isEmpty()) { - KGlobal::dirs()->addResourceDir("locale", translationsPath); - KLocalizedString::insertCatalog(runnerDescription.pluginName()); - } + // FIXME: Replace with ki18n functionality once semantics is clear. + // const QString translationsPath = package->filePath("translations"); + // if (!translationsPath.isEmpty()) { + // KGlobal::dirs()->addResourceDir("locale", translationsPath); + // } } } // Plasma namespace diff --git a/src/plasma/dataengine.cpp b/src/plasma/dataengine.cpp index 431378b52..d529536b9 100644 --- a/src/plasma/dataengine.cpp +++ b/src/plasma/dataengine.cpp @@ -580,11 +580,11 @@ void DataEnginePrivate::setupScriptSupport() << ", main script is" << package->filePath("mainscript"); */ - const QString translationsPath = package->filePath("translations"); - if (!translationsPath.isEmpty()) { - KGlobal::dirs()->addResourceDir("locale", translationsPath); - KLocalizedString::insertCatalog(dataEngineDescription.pluginName()); - } + // FIXME: Replace with ki18n functionality once semantics is clear. + // const QString translationsPath = package->filePath("translations"); + // if (!translationsPath.isEmpty()) { + // KGlobal::dirs()->addResourceDir("locale", translationsPath); + // } } void DataEnginePrivate::scheduleSourcesUpdated() diff --git a/src/plasma/private/applet_p.cpp b/src/plasma/private/applet_p.cpp index 3fc4c8499..b7fe4e948 100644 --- a/src/plasma/private/applet_p.cpp +++ b/src/plasma/private/applet_p.cpp @@ -298,11 +298,11 @@ void AppletPrivate::setupPackage() // << ", main script is" << package->filePath("mainscript"); #endif - const QString translationsPath = package->filePath("translations"); - if (!translationsPath.isEmpty()) { - KGlobal::dirs()->addResourceDir("locale", translationsPath); - KLocalizedString::insertCatalog(appletDescription.pluginName()); - } + // FIXME: Replace with ki18n functionality once semantics is clear. + // const QString translationsPath = package->filePath("translations"); + // if (!translationsPath.isEmpty()) { + // KGlobal::dirs()->addResourceDir("locale", translationsPath); + // } if (!package->filePath("mainconfigui").isEmpty()) { q->setHasConfigurationInterface(true); diff --git a/src/scriptengines/qml/plasmoid/declarativeappletscript.cpp b/src/scriptengines/qml/plasmoid/declarativeappletscript.cpp index 5509222d6..050734008 100644 --- a/src/scriptengines/qml/plasmoid/declarativeappletscript.cpp +++ b/src/scriptengines/qml/plasmoid/declarativeappletscript.cpp @@ -69,9 +69,6 @@ DeclarativeAppletScript::~DeclarativeAppletScript() bool DeclarativeAppletScript::init() { - //FIXME: what replaced this? - //KGlobal::locale()->insertCatalog("plasma_applet_" % description().pluginName()); - //make possible to import extensions from the package //FIXME: probably to be removed, would make possible to use native code from within the package :/ //m_interface->qmlObject()->engine()->addImportPath(package()->path()+"/contents/imports");