From 1d9fe41dd05d70c6fb9965c6fd6ae92efca43f6f Mon Sep 17 00:00:00 2001 From: Michail Vourlakos Date: Sun, 31 Jan 2021 11:27:57 +0200 Subject: [PATCH] move BasicItem into Abilities.Items --this way it can be used by ANY plasma applet --- .../abilities/items}/BasicItem.qml | 8 ++++---- .../abilities/items}/basicitem/HiddenSpacer.qml | 0 .../abilities/items/basicitem}/IndicatorLevel.qml | 0 .../abilities/items/basicitem}/ParabolicEventsArea.qml | 0 .../abilities/items/basicitem}/ParabolicItem.qml | 0 .../abilities/items/basicitem}/ShortcutBadge.qml | 0 .../abilities/items/basicitem}/TitleTooltipParent.qml | 0 declarativeimports/abilities/items/qmldir | 1 + plasmoid/package/contents/ui/task/TaskItem.qml | 2 +- 9 files changed, 6 insertions(+), 5 deletions(-) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items}/BasicItem.qml (98%) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items}/basicitem/HiddenSpacer.qml (100%) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items/basicitem}/IndicatorLevel.qml (100%) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items/basicitem}/ParabolicEventsArea.qml (100%) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items/basicitem}/ParabolicItem.qml (100%) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items/basicitem}/ShortcutBadge.qml (100%) rename {plasmoid/package/contents/ui/task => declarativeimports/abilities/items/basicitem}/TitleTooltipParent.qml (100%) diff --git a/plasmoid/package/contents/ui/task/BasicItem.qml b/declarativeimports/abilities/items/BasicItem.qml similarity index 98% rename from plasmoid/package/contents/ui/task/BasicItem.qml rename to declarativeimports/abilities/items/BasicItem.qml index 66943ed0f..e34076892 100644 --- a/plasmoid/package/contents/ui/task/BasicItem.qml +++ b/declarativeimports/abilities/items/BasicItem.qml @@ -265,7 +265,7 @@ Item{ } //! Indicator Back Layer - IndicatorLevel{ + BasicItemParts.IndicatorLevel{ id: indicatorBackLayer level.isBackground: true level.indicator: abilityIndicatorObj @@ -282,10 +282,10 @@ Item{ } } - ParabolicItem{id: _parabolicItem} + BasicItemParts.ParabolicItem{id: _parabolicItem} //! Indicator Front Layer - IndicatorLevel{ + BasicItemParts.IndicatorLevel{ id: indicatorFrontLayer level.isForeground: true level.indicator: abilityIndicatorObj @@ -301,7 +301,7 @@ Item{ width: plasmoid.formFactor === PlasmaCore.Types.Horizontal ? abilityItem.width : abilityItem.abilities.metrics.mask.thickness.zoomedForItems height: plasmoid.formFactor === PlasmaCore.Types.Horizontal ? abilityItem.abilities.metrics.mask.thickness.zoomedForItems : abilityItem.height z:10000 - sourceComponent: ParabolicEventsArea{} + sourceComponent: BasicItemParts.ParabolicEventsArea{} readonly property bool isParabolicEnabled: abilityItem.abilities.parabolic.isEnabled readonly property bool isThinTooltipEnabled: abilityItem.abilities.thinTooltip.isEnabled && abilityItem.thinTooltipText !== "" diff --git a/plasmoid/package/contents/ui/task/basicitem/HiddenSpacer.qml b/declarativeimports/abilities/items/basicitem/HiddenSpacer.qml similarity index 100% rename from plasmoid/package/contents/ui/task/basicitem/HiddenSpacer.qml rename to declarativeimports/abilities/items/basicitem/HiddenSpacer.qml diff --git a/plasmoid/package/contents/ui/task/IndicatorLevel.qml b/declarativeimports/abilities/items/basicitem/IndicatorLevel.qml similarity index 100% rename from plasmoid/package/contents/ui/task/IndicatorLevel.qml rename to declarativeimports/abilities/items/basicitem/IndicatorLevel.qml diff --git a/plasmoid/package/contents/ui/task/ParabolicEventsArea.qml b/declarativeimports/abilities/items/basicitem/ParabolicEventsArea.qml similarity index 100% rename from plasmoid/package/contents/ui/task/ParabolicEventsArea.qml rename to declarativeimports/abilities/items/basicitem/ParabolicEventsArea.qml diff --git a/plasmoid/package/contents/ui/task/ParabolicItem.qml b/declarativeimports/abilities/items/basicitem/ParabolicItem.qml similarity index 100% rename from plasmoid/package/contents/ui/task/ParabolicItem.qml rename to declarativeimports/abilities/items/basicitem/ParabolicItem.qml diff --git a/plasmoid/package/contents/ui/task/ShortcutBadge.qml b/declarativeimports/abilities/items/basicitem/ShortcutBadge.qml similarity index 100% rename from plasmoid/package/contents/ui/task/ShortcutBadge.qml rename to declarativeimports/abilities/items/basicitem/ShortcutBadge.qml diff --git a/plasmoid/package/contents/ui/task/TitleTooltipParent.qml b/declarativeimports/abilities/items/basicitem/TitleTooltipParent.qml similarity index 100% rename from plasmoid/package/contents/ui/task/TitleTooltipParent.qml rename to declarativeimports/abilities/items/basicitem/TitleTooltipParent.qml diff --git a/declarativeimports/abilities/items/qmldir b/declarativeimports/abilities/items/qmldir index f03bb323e..6b47abf75 100644 --- a/declarativeimports/abilities/items/qmldir +++ b/declarativeimports/abilities/items/qmldir @@ -1,4 +1,5 @@ module org.kde.latte.abilities.items +BasicItem 0.1 BasicItem.qml IndicatorLevel 0.1 IndicatorLevel.qml IndicatorObject 0.1 IndicatorObject.qml diff --git a/plasmoid/package/contents/ui/task/TaskItem.qml b/plasmoid/package/contents/ui/task/TaskItem.qml index 5b521f640..ca46b321b 100644 --- a/plasmoid/package/contents/ui/task/TaskItem.qml +++ b/plasmoid/package/contents/ui/task/TaskItem.qml @@ -35,7 +35,7 @@ import org.kde.latte.abilities.items 0.1 as AbilityItem import "animations" as TaskAnimations -BasicItem { +AbilityItem.BasicItem { id: taskItem visible: false objectName: "TaskItem"