From ad8195cad9a3a2d709e35c9034e669f9849004cb Mon Sep 17 00:00:00 2001 From: l10n daemon script Date: Tue, 21 May 2013 14:04:28 +0000 Subject: [PATCH 1/5] SVN_SILENT made messages (.desktop file) --- clients/aurorae/themes/plastik/package/metadata.desktop | 1 + 1 file changed, 1 insertion(+) diff --git a/clients/aurorae/themes/plastik/package/metadata.desktop b/clients/aurorae/themes/plastik/package/metadata.desktop index 0a77313cad..3b59f8eaad 100644 --- a/clients/aurorae/themes/plastik/package/metadata.desktop +++ b/clients/aurorae/themes/plastik/package/metadata.desktop @@ -92,6 +92,7 @@ Comment=The classic theme known from KDE 3 Comment[bs]=Klasična tema iz KDE 3 Comment[ca]=El tema clàssic conegut des del KDE 3 Comment[ca@valencia]=El tema clàssic conegut des del KDE 3 +Comment[cs]=Klasický motiv známý z KDE 3 Comment[da]=Det klassiske tema som er kendt fra KDE 3 Comment[de]=Das klassische Design aus KDE 3 Comment[el]=Το γνωστό κλασικό θέμα από το KDE 3 From b4a70ca2ef534557e8232d3193016c851ac350e3 Mon Sep 17 00:00:00 2001 From: l10n daemon script Date: Fri, 24 May 2013 05:48:46 +0000 Subject: [PATCH 2/5] SVN_SILENT made messages (.desktop file) --- effects/slideback/slideback.desktop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/effects/slideback/slideback.desktop b/effects/slideback/slideback.desktop index 694dfef176..ea01a12e1a 100644 --- a/effects/slideback/slideback.desktop +++ b/effects/slideback/slideback.desktop @@ -49,7 +49,7 @@ Name[pl]=Przesuń w tył Name[pt]=Deslizar para Trás Name[pt_BR]=Deslizar para trás Name[ro]=Alunecă în spate -Name[ru]=Выскальзывание +Name[ru]=Соскальзывание Name[si]=ආපසු ලිස්සන්න Name[sk]=Zasunúť Name[sl]=Zdrs v ozadje From bf044bf509a1753c689e33b49e74074965e35331 Mon Sep 17 00:00:00 2001 From: Oliver Henshaw Date: Thu, 23 May 2013 17:18:48 +0100 Subject: [PATCH 3/5] Drop unneeded duplicate addImportPath Let KDeclarative::setupBindings() add the import paths: it too takes paths from KGlobal::dirs()->findDirs("module", "imports"); it adds paths in the correct (reverse) order [1]. [1] See kdelibs 400b9f2e9d10386bb175b6123fe0cdaafeaffe61 for further details. REVIEW: 110670 --- scripting/scripting.cpp | 5 ----- tabbox/declarative.cpp | 3 --- 2 files changed, 8 deletions(-) diff --git a/scripting/scripting.cpp b/scripting/scripting.cpp index 13a77bc346..16a696c6cf 100644 --- a/scripting/scripting.cpp +++ b/scripting/scripting.cpp @@ -550,11 +550,6 @@ void KWin::DeclarativeScript::run() pal.setColor(m_view->backgroundRole(), Qt::transparent); m_view->setPalette(pal); - - foreach (const QString &importPath, KGlobal::dirs()->findDirs("module", "imports")) { - m_view->engine()->addImportPath(importPath); - } - // add read config KDeclarative kdeclarative; kdeclarative.setDeclarativeEngine(m_view->engine()); diff --git a/tabbox/declarative.cpp b/tabbox/declarative.cpp index f759512c76..7f169dcb02 100644 --- a/tabbox/declarative.cpp +++ b/tabbox/declarative.cpp @@ -138,9 +138,6 @@ DeclarativeView::DeclarativeView(QAbstractItemModel *model, TabBoxConfig::TabBox QPalette pal = palette(); pal.setColor(backgroundRole(), Qt::transparent); setPalette(pal); - foreach (const QString &importPath, KGlobal::dirs()->findDirs("module", "imports")) { - engine()->addImportPath(importPath); - } engine()->addImageProvider(QLatin1String("client"), new ImageProvider(model)); KDeclarative kdeclarative; kdeclarative.setDeclarativeEngine(engine()); From 2d5ebd3b8d71a72b19598d7c1bf67fa649ef6d6d Mon Sep 17 00:00:00 2001 From: Oliver Henshaw Date: Sun, 26 May 2013 14:09:22 +0100 Subject: [PATCH 4/5] Replace foreach with java-style iterator In preparation for reversing the loop. REVIEW: 110670 --- clients/aurorae/src/aurorae.cpp | 10 ++++++---- kcmkwin/kwindecoration/kwindecoration.cpp | 5 +++-- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/clients/aurorae/src/aurorae.cpp b/clients/aurorae/src/aurorae.cpp index f7771c4cbe..3da750b1b8 100644 --- a/clients/aurorae/src/aurorae.cpp +++ b/clients/aurorae/src/aurorae.cpp @@ -88,8 +88,9 @@ void AuroraeFactory::initAurorae(KConfig &conf, KConfigGroup &group) m_theme->setButtonSize((KDecorationDefines::BorderSize)themeGroup.readEntry("ButtonSize", KDecorationDefines::BorderNormal)); m_theme->setTabDragMimeType(tabDragMimeType()); // setup the QML engine - foreach (const QString &importPath, KGlobal::dirs()->findDirs("module", "imports")) { - m_engine->addImportPath(importPath); + QStringListIterator paths(KGlobal::dirs()->findDirs("module", "imports")); + while (paths.hasNext()) { + m_engine->addImportPath(paths.next()); } m_component->loadUrl(QUrl(KStandardDirs::locate("data", "kwin/aurorae/aurorae.qml"))); m_engine->rootContext()->setContextProperty("auroraeTheme", m_theme); @@ -122,8 +123,9 @@ void AuroraeFactory::initQML(const KConfigGroup &group) } m_engineType = QMLEngine; // setup the QML engine - foreach (const QString &importPath, KGlobal::dirs()->findDirs("module", "imports")) { - m_engine->addImportPath(importPath); + QStringListIterator paths(KGlobal::dirs()->findDirs("module", "imports")); + while (paths.hasNext()) { + m_engine->addImportPath(paths.next()); } m_component->loadUrl(QUrl::fromLocalFile(file)); m_themeName = themeName; diff --git a/kcmkwin/kwindecoration/kwindecoration.cpp b/kcmkwin/kwindecoration/kwindecoration.cpp index 591a913c40..788483e252 100644 --- a/kcmkwin/kwindecoration/kwindecoration.cpp +++ b/kcmkwin/kwindecoration/kwindecoration.cpp @@ -135,8 +135,9 @@ void KWinDecorationModule::init() m_proxyModel->setSourceModel(m_model); m_proxyModel->setFilterCaseSensitivity(Qt::CaseInsensitive); m_ui->decorationList->setResizeMode(QDeclarativeView::SizeRootObjectToView); - foreach (const QString &importPath, KGlobal::dirs()->findDirs("module", "imports")) { - m_ui->decorationList->engine()->addImportPath(importPath); + QStringListIterator paths(KGlobal::dirs()->findDirs("module", "imports")); + while (paths.hasNext()) { + m_ui->decorationList->engine()->addImportPath(paths.next()); } m_ui->decorationList->rootContext()->setContextProperty("decorationModel", m_proxyModel); m_ui->decorationList->rootContext()->setContextProperty("decorationBaseModel", m_model); From b61bca0f3d4415f32a25a1e37103c1bb4f183687 Mon Sep 17 00:00:00 2001 From: Oliver Henshaw Date: Sun, 26 May 2013 14:32:21 +0100 Subject: [PATCH 5/5] add qml import paths in correct order addImportPath prepends the path to importPathList so we must add our paths in reverse order. Based on the fix for kdeclarative.cpp in kdelibs 400b9f2e9d10386bb175b6123fe0cdaafeaffe61 REVIEW: 110670 --- clients/aurorae/src/aurorae.cpp | 16 ++++++++++++---- kcmkwin/kwindecoration/kwindecoration.cpp | 8 ++++++-- 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/clients/aurorae/src/aurorae.cpp b/clients/aurorae/src/aurorae.cpp index 3da750b1b8..6881ae9ed0 100644 --- a/clients/aurorae/src/aurorae.cpp +++ b/clients/aurorae/src/aurorae.cpp @@ -88,9 +88,13 @@ void AuroraeFactory::initAurorae(KConfig &conf, KConfigGroup &group) m_theme->setButtonSize((KDecorationDefines::BorderSize)themeGroup.readEntry("ButtonSize", KDecorationDefines::BorderNormal)); m_theme->setTabDragMimeType(tabDragMimeType()); // setup the QML engine + /* use logic from KDeclarative::setupBindings(): + "addImportPath adds the path at the beginning, so to honour user's + paths we need to traverse the list in reverse order" */ QStringListIterator paths(KGlobal::dirs()->findDirs("module", "imports")); - while (paths.hasNext()) { - m_engine->addImportPath(paths.next()); + paths.toBack(); + while (paths.hasPrevious()) { + m_engine->addImportPath(paths.previous()); } m_component->loadUrl(QUrl(KStandardDirs::locate("data", "kwin/aurorae/aurorae.qml"))); m_engine->rootContext()->setContextProperty("auroraeTheme", m_theme); @@ -123,9 +127,13 @@ void AuroraeFactory::initQML(const KConfigGroup &group) } m_engineType = QMLEngine; // setup the QML engine + /* use logic from KDeclarative::setupBindings(): + "addImportPath adds the path at the beginning, so to honour user's + paths we need to traverse the list in reverse order" */ QStringListIterator paths(KGlobal::dirs()->findDirs("module", "imports")); - while (paths.hasNext()) { - m_engine->addImportPath(paths.next()); + paths.toBack(); + while (paths.hasPrevious()) { + m_engine->addImportPath(paths.previous()); } m_component->loadUrl(QUrl::fromLocalFile(file)); m_themeName = themeName; diff --git a/kcmkwin/kwindecoration/kwindecoration.cpp b/kcmkwin/kwindecoration/kwindecoration.cpp index 788483e252..6bb8a744f5 100644 --- a/kcmkwin/kwindecoration/kwindecoration.cpp +++ b/kcmkwin/kwindecoration/kwindecoration.cpp @@ -135,9 +135,13 @@ void KWinDecorationModule::init() m_proxyModel->setSourceModel(m_model); m_proxyModel->setFilterCaseSensitivity(Qt::CaseInsensitive); m_ui->decorationList->setResizeMode(QDeclarativeView::SizeRootObjectToView); + /* use logic from KDeclarative::setupBindings(): + "addImportPath adds the path at the beginning, so to honour user's + paths we need to traverse the list in reverse order" */ QStringListIterator paths(KGlobal::dirs()->findDirs("module", "imports")); - while (paths.hasNext()) { - m_ui->decorationList->engine()->addImportPath(paths.next()); + paths.toBack(); + while (paths.hasPrevious()) { + m_ui->decorationList->engine()->addImportPath(paths.previous()); } m_ui->decorationList->rootContext()->setContextProperty("decorationModel", m_proxyModel); m_ui->decorationList->rootContext()->setContextProperty("decorationBaseModel", m_model);