simplify indicators names

pull/5/head
Michail Vourlakos 6 years ago
parent 5e420b597b
commit 28ef36a774

@ -37,7 +37,7 @@ Factory::Factory(QObject *parent)
{ {
reload(); reload();
qDebug() << m_plugins["org.kde.latte.indicator.default"].name(); qDebug() << m_plugins["org.kde.latte.default"].name();
} }
Factory::~Factory() Factory::~Factory()

@ -214,8 +214,8 @@ void Indicator::load(QString type)
//! create all indicators with the new type //! create all indicators with the new type
setPluginIsReady(true); setPluginIsReady(true);
} else if (type!="org.kde.latte.indicator.default") { } else if (type!="org.kde.latte.default") {
setType("org.kde.latte.indicator.default"); setType("org.kde.latte.default");
} }
} }
@ -239,7 +239,7 @@ void Indicator::loadPlasmaComponent()
{ {
auto prevComponent = m_plasmaComponent; auto prevComponent = m_plasmaComponent;
KPluginMetaData metadata = m_corona->indicatorFactory()->metadata("org.kde.latte.indicator.plasma"); KPluginMetaData metadata = m_corona->indicatorFactory()->metadata("org.kde.latte.plasma");
QString uiPath = metadata.value("X-Latte-MainScript"); QString uiPath = metadata.value("X-Latte-MainScript");
if (!uiPath.isEmpty()) { if (!uiPath.isEmpty()) {
@ -328,7 +328,7 @@ void Indicator::loadConfig()
m_enabledForApplets = config.readEntry("enabledForApplets", true); m_enabledForApplets = config.readEntry("enabledForApplets", true);
m_padding = config.readEntry("padding", (float)0.08); m_padding = config.readEntry("padding", (float)0.08);
m_reversed = config.readEntry("reversed", false); m_reversed = config.readEntry("reversed", false);
m_type = config.readEntry("type", "org.kde.latte.indicator.default"); m_type = config.readEntry("type", "org.kde.latte.default");
} }
void Indicator::saveConfig() void Indicator::saveConfig()

@ -132,7 +132,7 @@ private:
float m_padding{0.08}; float m_padding{0.08};
QString m_pluginPath; QString m_pluginPath;
QString m_type{"org.kde.latte.indicator.default"}; QString m_type{"org.kde.latte.default"};
QPointer<QQmlComponent> m_component; QPointer<QQmlComponent> m_component;
QPointer<QQmlComponent> m_plasmaComponent; QPointer<QQmlComponent> m_plasmaComponent;

@ -35,7 +35,7 @@ Item{
readonly property bool enabledForApplets: latteView && latteView.indicator ? latteView.indicator.enabledForApplets : true readonly property bool enabledForApplets: latteView && latteView.indicator ? latteView.indicator.enabledForApplets : true
readonly property bool reversed: latteView && latteView.indicator ? latteView.indicator.reversed : false readonly property bool reversed: latteView && latteView.indicator ? latteView.indicator.reversed : false
readonly property real padding: latteView && latteView.indicator ? latteView.indicator.padding: 0.08 readonly property real padding: latteView && latteView.indicator ? latteView.indicator.padding: 0.08
readonly property string type: latteView && latteView.indicator ? latteView.indicator.type : "org.kde.latte.indicator.default" readonly property string type: latteView && latteView.indicator ? latteView.indicator.type : "org.kde.latte.default"
readonly property Component plasmaStyleComponent: latteView && latteView.indicator ? latteView.indicator.plasmaComponent : null readonly property Component plasmaStyleComponent: latteView && latteView.indicator ? latteView.indicator.plasmaComponent : null
readonly property Component indicatorComponent: latteView && latteView.indicator ? latteView.indicator.component : null readonly property Component indicatorComponent: latteView && latteView.indicator ? latteView.indicator.component : null

@ -1,3 +1,3 @@
install(DIRECTORY default DESTINATION ${CMAKE_INSTALL_PREFIX}/share/latte/indicators) install(DIRECTORY default DESTINATION ${CMAKE_INSTALL_PREFIX}/share/latte/indicators)
install(DIRECTORY org.kde.latte.indicator.plasma DESTINATION ${CMAKE_INSTALL_PREFIX}/share/latte/indicators) install(DIRECTORY org.kde.latte.plasma DESTINATION ${CMAKE_INSTALL_PREFIX}/share/latte/indicators)
install(DIRECTORY org.kde.latte.indicator.unity DESTINATION ${CMAKE_INSTALL_PREFIX}/share/latte/indicators) install(DIRECTORY org.kde.latte.unity DESTINATION ${CMAKE_INSTALL_PREFIX}/share/latte/indicators)

@ -1,4 +1,4 @@
#! /usr/bin/env bash #! /usr/bin/env bash
$XGETTEXT `find default -name \*.js -o -name \*.qml -o -name \*.cpp` -o $podir/latte_indicator_org.kde.latte.indicator.default.pot $XGETTEXT `find default -name \*.js -o -name \*.qml -o -name \*.cpp` -o $podir/latte_indicator_org.kde.latte.default.pot
$XGETTEXT `find org.kde.latte.indicator.plasma -name \*.js -o -name \*.qml -o -name \*.cpp` -o $podir/latte_indicator_org.kde.latte.indicator.plasma.pot $XGETTEXT `find org.kde.latte.plasma -name \*.js -o -name \*.qml -o -name \*.cpp` -o $podir/latte_indicator_org.kde.latte.plasma.pot

@ -11,7 +11,7 @@ X-Latte-ConfigXml=config/main.xml
X-KDE-PluginInfo-Author=Michail Vourlakos X-KDE-PluginInfo-Author=Michail Vourlakos
X-KDE-PluginInfo-Email=mvourlakos@gmail.com X-KDE-PluginInfo-Email=mvourlakos@gmail.com
X-KDE-PluginInfo-Name=org.kde.latte.indicator.default X-KDE-PluginInfo-Name=org.kde.latte.default
X-KDE-PluginInfo-Version=0.1 X-KDE-PluginInfo-Version=0.1
X-KDE-PluginInfo-Category=Latte Indicator X-KDE-PluginInfo-Category=Latte Indicator
X-KDE-PluginInfo-License=GPL v2+ X-KDE-PluginInfo-License=GPL v2+

@ -9,7 +9,7 @@ X-Latte-MainScript=ui/main.qml
X-KDE-PluginInfo-Author=Michail Vourlakos X-KDE-PluginInfo-Author=Michail Vourlakos
X-KDE-PluginInfo-Email=mvourlakos@gmail.com X-KDE-PluginInfo-Email=mvourlakos@gmail.com
X-KDE-PluginInfo-Name=org.kde.latte.indicator.plasma X-KDE-PluginInfo-Name=org.kde.latte.plasma
X-KDE-PluginInfo-Version=0.1 X-KDE-PluginInfo-Version=0.1
X-KDE-PluginInfo-Category=Latte Indicator X-KDE-PluginInfo-Category=Latte Indicator
X-KDE-PluginInfo-License=GPL v2+ X-KDE-PluginInfo-License=GPL v2+

@ -9,7 +9,7 @@ X-Latte-MainScript=ui/main.qml
X-KDE-PluginInfo-Author=Michail Vourlakos X-KDE-PluginInfo-Author=Michail Vourlakos
X-KDE-PluginInfo-Email=mvourlakos@gmail.com X-KDE-PluginInfo-Email=mvourlakos@gmail.com
X-KDE-PluginInfo-Name=org.kde.latte.indicator.unity X-KDE-PluginInfo-Name=org.kde.latte.unity
X-KDE-PluginInfo-Version=0.1 X-KDE-PluginInfo-Version=0.1
X-KDE-PluginInfo-Category=Latte Indicator X-KDE-PluginInfo-Category=Latte Indicator
X-KDE-PluginInfo-License=GPL v2+ X-KDE-PluginInfo-License=GPL v2+

@ -35,7 +35,7 @@ Item{
readonly property bool isEnabled: true readonly property bool isEnabled: true
readonly property bool reversed: plasmoid.configuration.reverseLinesPosition readonly property bool reversed: plasmoid.configuration.reverseLinesPosition
readonly property string type: "org.kde.latte.indicator.default" readonly property string type: "org.kde.latte.default"
readonly property Component indicatorComponent: latteStyleIndicator readonly property Component indicatorComponent: latteStyleIndicator

@ -492,7 +492,7 @@ PlasmaComponents.Page {
exclusiveGroup: indicatorStyleGroup exclusiveGroup: indicatorStyleGroup
tooltip: i18n("Use Latte style for your indicators") tooltip: i18n("Use Latte style for your indicators")
readonly property string type: "org.kde.latte.indicator.default" readonly property string type: "org.kde.latte.default"
} }
PlasmaComponents.Button { PlasmaComponents.Button {
@ -503,7 +503,7 @@ PlasmaComponents.Page {
exclusiveGroup: indicatorStyleGroup exclusiveGroup: indicatorStyleGroup
tooltip: i18n("Use Plasma style for your indicators") tooltip: i18n("Use Plasma style for your indicators")
readonly property string type: "org.kde.latte.indicator.plasma" readonly property string type: "org.kde.latte.plasma"
} }
PlasmaComponents.Button { PlasmaComponents.Button {
@ -514,7 +514,7 @@ PlasmaComponents.Page {
exclusiveGroup: indicatorStyleGroup exclusiveGroup: indicatorStyleGroup
tooltip: i18n("Use Unity style for your indicators") tooltip: i18n("Use Unity style for your indicators")
readonly property string type: "org.kde.latte.indicator.unity" readonly property string type: "org.kde.latte.unity"
} }
} }

Loading…
Cancel
Save