1
0
mirror of https://github.com/KDE/latte-dock.git synced 2025-01-13 05:17:48 +03:00

init earlier translation domain, indicatorconfigui

This commit is contained in:
Michail Vourlakos 2019-04-01 17:15:43 +03:00
parent 82480e6079
commit 9f1b284f64

View File

@ -332,14 +332,13 @@ void Indicator::configUiFor(QString type, QQuickItem *parent)
if (!uiPath.isEmpty()) {
m_lastCreatedConfigUi = new KDeclarative::QmlObjectSharedEngine(parent);
m_lastCreatedConfigUi->setTranslationDomain(QLatin1String("latte_indicator_") + m_metadata.pluginId());
m_lastCreatedConfigUi->setInitializationDelayed(true);
uiPath = m_pluginPath + "package/" + uiPath;
m_lastCreatedConfigUi->setSource(QUrl::fromLocalFile(uiPath));
m_lastCreatedConfigUi->rootContext()->setContextProperty(QStringLiteral("indicator"), this);
m_lastCreatedConfigUi->completeInitialization();
m_lastCreatedConfigUi->setTranslationDomain(QLatin1String("latte_indicator_") + m_metadata.pluginId());
QQuickItem *qmlItem = qobject_cast<QQuickItem*>(m_lastCreatedConfigUi->rootObject());
qmlItem->setParentItem(parent);