mirror of
https://github.com/end-4/dots-hyprland.git
synced 2026-06-05 14:59:27 -05:00
add hiding animation to hands
This commit is contained in:
@@ -198,10 +198,13 @@ Item {
|
||||
|
||||
// Hour hand
|
||||
Item {
|
||||
visible: Config.options.background.clock.cookie.hourHandStyle === "hide" ? false : true
|
||||
opacity: Config.options.background.clock.cookie.hourHandStyle === "hide" ? 0.0 : 1.0
|
||||
anchors.fill: parent
|
||||
z: Config.options.background.clock.cookie.hourHandStyle === "fill" ? 3 : 1
|
||||
rotation: -90 + (360 / 12) * (root.clockHour + root.clockMinute / 60)
|
||||
Behavior on opacity {
|
||||
animation: Appearance.animation.elementMoveFast.numberAnimation.createObject(this)
|
||||
}
|
||||
Rectangle {
|
||||
opacity: Config.options.background.clock.cookie.hourHandStyle !== "hide" ? 1.0 : 0
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
@@ -223,13 +226,16 @@ Item {
|
||||
|
||||
// Minute hand
|
||||
Item {
|
||||
visible: Config.options.background.clock.cookie.minuteHandStyle === "hide" ? false : true
|
||||
opacity: Config.options.background.clock.cookie.minuteHandStyle === "hide" ? 0.0 : 1.0
|
||||
anchors.fill: parent
|
||||
z: Config.options.background.clock.cookie.minuteHandStyle === "thin" ? 1 : 3
|
||||
rotation: -90 + (360 / 60) * root.clockMinute
|
||||
Behavior on rotation{
|
||||
animation: Appearance.animation.elementResize.numberAnimation.createObject(this)
|
||||
}
|
||||
Behavior on opacity {
|
||||
animation: Appearance.animation.elementResize.numberAnimation.createObject(this)
|
||||
}
|
||||
Rectangle {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
x: Config.options.background.clock.cookie.minuteHandStyle === "classic" ? (parent.width / 2 - minuteHandWidth / 2) - 15 : parent.width / 2 - minuteHandWidth / 2
|
||||
|
||||
@@ -134,16 +134,16 @@ ContentPage {
|
||||
icon: "radio",
|
||||
value: "classic"
|
||||
},
|
||||
{
|
||||
displayName: Translation.tr("Fill"),
|
||||
icon: "stroke_full",
|
||||
value: "fill"
|
||||
},
|
||||
{
|
||||
displayName: Translation.tr("Stroke"),
|
||||
icon: "stroke_partial",
|
||||
value: "stroke"
|
||||
},
|
||||
{
|
||||
displayName: Translation.tr("Fill"),
|
||||
icon: "stroke_full",
|
||||
value: "fill"
|
||||
},
|
||||
{
|
||||
displayName: Translation.tr("Hide"),
|
||||
icon: "deselect",
|
||||
|
||||
Reference in New Issue
Block a user