mirror of
https://github.com/KDE/latte-dock.git
synced 2025-01-12 01:17:55 +03:00
restore slide-out remove window animation
--update it to Kirigami.Icon infrastructure
This commit is contained in:
parent
08118d531c
commit
4be537d24d
@ -80,9 +80,6 @@ Item {
|
||||
id: taskIconItem
|
||||
anchors.fill: parent
|
||||
//roundToIconSize: false
|
||||
//! Trying to provide crisp icons for regular and zoomed size and smooth appearance in-between
|
||||
//! bug:432477
|
||||
//smooth: size !== taskItem.abilities.metrics.iconSize && size !== (taskItem.abilities.metrics.iconSize*taskItem.abilities.parabolic.zoom)
|
||||
source: decoration
|
||||
visible: !badgesLoader.active
|
||||
|
||||
|
@ -24,6 +24,8 @@ import QtGraphicalEffects 1.0
|
||||
import org.kde.plasma.plasmoid 2.0
|
||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||
|
||||
import org.kde.kirigami 2.0 as Kirigami
|
||||
|
||||
import org.kde.latte.core 0.2 as LatteCore
|
||||
|
||||
/////Removing a Window from a group////
|
||||
@ -62,30 +64,9 @@ Item{
|
||||
id: removeTask
|
||||
width: taskIcon.width
|
||||
height: taskIcon.height
|
||||
|
||||
visible: false
|
||||
|
||||
LatteCore.IconItem{
|
||||
id: tempRemoveIcon
|
||||
anchors.rightMargin: root.location === PlasmaCore.Types.LeftEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
anchors.leftMargin: root.location === PlasmaCore.Types.RightEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
anchors.topMargin: root.location === PlasmaCore.Types.BottomEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
anchors.bottomMargin: root.location === PlasmaCore.Types.TopEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
|
||||
anchors.horizontalCenter: !root.vertical ? parent.horizontalCenter : undefined;
|
||||
anchors.verticalCenter: root.vertical ? parent.verticalCenter : undefined;
|
||||
anchors.right: root.location === PlasmaCore.Types.LeftEdge ? parent.right : undefined;
|
||||
anchors.left: root.location === PlasmaCore.Types.RightEdge ? parent.left : undefined;
|
||||
anchors.top: root.location === PlasmaCore.Types.BottomEdge ? parent.top : undefined;
|
||||
anchors.bottom: root.location === PlasmaCore.Types.TopEdge ? parent.bottom : undefined;
|
||||
|
||||
width: taskIconItem.width
|
||||
height: width
|
||||
visible: taskItem.abilities.myView.itemShadow.isEnabled ? false : true
|
||||
|
||||
source: taskIconItem.lastValidSourceName
|
||||
}
|
||||
|
||||
//! Shadow
|
||||
Loader{
|
||||
id: tempTaskShadow
|
||||
anchors.fill: tempRemoveIcon
|
||||
@ -102,6 +83,28 @@ Item{
|
||||
}
|
||||
}
|
||||
|
||||
Kirigami.Icon{
|
||||
id: tempRemoveIcon
|
||||
anchors.rightMargin: root.location === PlasmaCore.Types.LeftEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
anchors.leftMargin: root.location === PlasmaCore.Types.RightEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
anchors.topMargin: root.location === PlasmaCore.Types.BottomEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
anchors.bottomMargin: root.location === PlasmaCore.Types.TopEdge ? taskItem.abilities.metrics.margin.thickness : 0
|
||||
|
||||
anchors.horizontalCenter: !root.vertical ? parent.horizontalCenter : undefined;
|
||||
anchors.verticalCenter: root.vertical ? parent.verticalCenter : undefined;
|
||||
anchors.right: root.location === PlasmaCore.Types.LeftEdge ? parent.right : undefined;
|
||||
anchors.left: root.location === PlasmaCore.Types.RightEdge ? parent.left : undefined;
|
||||
anchors.top: root.location === PlasmaCore.Types.BottomEdge ? parent.top : undefined;
|
||||
anchors.bottom: root.location === PlasmaCore.Types.TopEdge ? parent.bottom : undefined;
|
||||
|
||||
width: taskIconItem.width
|
||||
height: width
|
||||
|
||||
source: taskIconItem.source
|
||||
}
|
||||
|
||||
|
||||
|
||||
Colorize{
|
||||
source: tempRemoveIcon
|
||||
anchors.fill: tempRemoveIcon
|
||||
|
Loading…
Reference in New Issue
Block a user