Simplify startup and improve its animation
- Remove Python.loadingAccounts/willLoadAccounts - Fix HPage SwipeView bug that caused its inner SidePane to steal focus - Use overshoot for animation - Get rid of sidepane flickering - Set default HNumberAnimation easing.type to OutQuad, specify InOutQuad for HCheckBox
This commit is contained in:
@@ -30,7 +30,12 @@ CheckBox {
|
||||
|
||||
visible: scale > 0
|
||||
scale: box.checked ? 1 : 0
|
||||
Behavior on scale { HNumberAnimation { overshoot: 4 } }
|
||||
Behavior on scale {
|
||||
HNumberAnimation {
|
||||
overshoot: 4
|
||||
easing.type: Easing.InOutBack
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -1,10 +1,10 @@
|
||||
import QtQuick 2.12
|
||||
|
||||
NumberAnimation {
|
||||
property real factor: Math.max(overshoot / 1.75, 1.0)
|
||||
property real factor: 1.0
|
||||
property real overshoot: 1.0
|
||||
|
||||
duration: theme.animationDuration * factor
|
||||
easing.type: overshoot > 1 ? Easing.InOutBack : Easing.Linear
|
||||
duration: theme.animationDuration * Math.max(overshoot / 1.7, 1.0) * factor
|
||||
easing.type: overshoot > 1 ? Easing.OutBack : Easing.Linear
|
||||
easing.overshoot: overshoot
|
||||
}
|
||||
|
@@ -18,12 +18,13 @@ SwipeView {
|
||||
Math.min(theme.spacing * width / 400, theme.spacing)
|
||||
|
||||
id: swipeView
|
||||
currentIndex: 1
|
||||
clip: true
|
||||
interactive: sidePane.reduce
|
||||
currentIndex: 1
|
||||
|
||||
SidePane {
|
||||
implicitWidth: swipeView.width
|
||||
animateWidth: false // Without this, the SidePane gets auto-focused
|
||||
collapse: false
|
||||
reduce: false
|
||||
visible: swipeView.interactive
|
||||
|
Reference in New Issue
Block a user