From 836da98cec2cfca3e6a807f10dfc6350d954e1ac Mon Sep 17 00:00:00 2001 From: Michail Vourlakos Date: Wed, 3 Feb 2021 18:52:35 +0200 Subject: [PATCH] use PlasmaCore.IconItems everywhere in tasks --- plasmoid/package/contents/ui/task/TaskIcon.qml | 12 +++++++++--- .../contents/ui/task/animations/ClickedAnimation.qml | 2 +- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/plasmoid/package/contents/ui/task/TaskIcon.qml b/plasmoid/package/contents/ui/task/TaskIcon.qml index 43782b72a..7cd9b29e7 100644 --- a/plasmoid/package/contents/ui/task/TaskIcon.qml +++ b/plasmoid/package/contents/ui/task/TaskIcon.qml @@ -79,7 +79,9 @@ Item { anchors.fill: parent roundToIconSize: false source: decoration - smooth: false + //! trying to avoid pixelated icons because of hovering animation triggered from PlasmaCore.IconItem + smooth: taskItem.parabolicItem.zoom > 1 && taskItem.parabolicItem.zoom < taskItem.abilities.parabolic.zoom + active: (taskItem.containsMouse && !taskItem.abilities.indicators.info.providesHoveredAnimation) visible: !badgesLoader.active @@ -157,10 +159,13 @@ Item { enabled: false anchors.fill: parent property var source: ShaderEffectSource { - sourceItem: LatteCore.IconItem{ + sourceItem: PlasmaCore.IconItem{ width: taskIconContainer.width height: taskIconContainer.height + smooth: taskIconItem.smooth source: taskIconItem.source + roundToIconSize: taskIconItem.roundToIconSize + active: taskIconItem.roundToIconSize Loader{ anchors.fill: parent @@ -392,6 +397,7 @@ Item { lightness:0 } + /* Rely on PlasmaCore.IconItem hovering animation for now BrightnessContrast{ id:hoveredImage anchors.fill: parent @@ -412,7 +418,7 @@ Item { Behavior on opacity { NumberAnimation { duration: taskItem.abilities.animations.speedFactor.current * taskItem.abilities.animations.duration.large } } - } + }*/ BrightnessContrast { id: brightnessTaskEffect diff --git a/plasmoid/package/contents/ui/task/animations/ClickedAnimation.qml b/plasmoid/package/contents/ui/task/animations/ClickedAnimation.qml index 59b5bae95..54175ba2a 100644 --- a/plasmoid/package/contents/ui/task/animations/ClickedAnimation.qml +++ b/plasmoid/package/contents/ui/task/animations/ClickedAnimation.qml @@ -46,7 +46,7 @@ SequentialAnimation{ onPressedChanged: { if(!running && pressed && !taskItem.abilities.indicators.info.providesClickedAnimation && - ((taskItem.lastButtonClicked == Qt.LeftButton)||(taskItem.lastButtonClicked === Qt.MidButton)) ){ + ((taskItem.lastButtonClicked === Qt.LeftButton)||(taskItem.lastButtonClicked === Qt.MidButton)) ){ start(); } }