Commit b70b34b7 authored by Noah Davis's avatar Noah Davis 🌵
Browse files

ImageViewer: Make all floating controls disappear when dragging or using overview

parent c85912f5
......@@ -686,12 +686,17 @@ Kirigami.Page {
listView.currentIndex -= 1;
}
opacity: !Kirigami.Settings.isMobile && applicationWindow().controlsVisible && listView.currentIndex > 0 ? 1 : 0
visible: !Kirigami.Settings.isMobile // Using `&& opacity > 0` causes reappearing to be delayed
opacity: applicationWindow().controlsVisible
&& listView.currentIndex > 0
&& !listView.isCurrentItemDragging
&& !overviewControl.pressed
? 1 : 0
Behavior on opacity {
OpacityAnimator {
duration: Kirigami.Units.longDuration
easing.type: Easing.InOutQuad
easing.type: !applicationWindow().controlsVisible ? Easing.InOutQuad : Easing.InCubic
}
}
}
......@@ -711,12 +716,17 @@ Kirigami.Page {
listView.currentIndex += 1;
}
opacity: !Kirigami.Settings.isMobile && applicationWindow().controlsVisible && listView.currentIndex < listView.count - 1 ? 1 : 0
visible: !Kirigami.Settings.isMobile // Using `&& opacity > 0` causes flickering
opacity: applicationWindow().controlsVisible
&& listView.currentIndex < listView.count - 1
&& !listView.isCurrentItemDragging
&& !overviewControl.pressed
? 1 : 0
Behavior on opacity {
OpacityAnimator {
duration: Kirigami.Units.longDuration
easing.type: Easing.InOutQuad
easing.type: !applicationWindow().controlsVisible ? Easing.InOutQuad : Easing.InCubic
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment