mirror of
https://code.videolan.org/videolan/vlc
synced 2024-10-03 01:31:53 +02:00
qml: Update to VLCStyle duration implementation
This commit is contained in:
parent
75470d892b
commit
b83abff28f
@ -48,15 +48,29 @@ ListView {
|
||||
}
|
||||
|
||||
remove: Transition {
|
||||
NumberAnimation { property: "opacity"; from: 1.0; to: 0; duration: 200 }
|
||||
NumberAnimation {
|
||||
property: "opacity"; from: 1.0; to: 0
|
||||
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
|
||||
add: Transition {
|
||||
NumberAnimation { property: "opacity"; from: 0; to: 1.0; duration: 200 }
|
||||
NumberAnimation {
|
||||
property: "opacity"; from: 0; to: 1.0
|
||||
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
|
||||
displaced: Transition {
|
||||
NumberAnimation { properties: "x"; duration: 200; easing.type: Easing.OutSine }
|
||||
NumberAnimation {
|
||||
properties: "x"
|
||||
|
||||
duration: VLCStyle.duration_normal
|
||||
easing.type: Easing.OutSine
|
||||
}
|
||||
|
||||
NumberAnimation { property: "opacity"; to: 1.0 }
|
||||
}
|
||||
|
||||
|
@ -286,7 +286,13 @@ FocusScope {
|
||||
to: "collapsed"
|
||||
|
||||
SequentialAnimation {
|
||||
SmoothedAnimation { target: playlistColumn; property: "width"; easing.type: Easing.OutSine; duration: 150; }
|
||||
SmoothedAnimation {
|
||||
target: playlistColumn; property: "width"
|
||||
|
||||
duration: VLCStyle.duration_fast
|
||||
easing.type: Easing.OutSine
|
||||
}
|
||||
|
||||
PropertyAction { target: playlistColumn; property: "visible" }
|
||||
}
|
||||
},
|
||||
@ -297,7 +303,13 @@ FocusScope {
|
||||
|
||||
SequentialAnimation {
|
||||
PropertyAction { target: playlistColumn; property: "visible" }
|
||||
SmoothedAnimation { target: playlistColumn; property: "width"; easing.type: Easing.InSine; duration: 150; }
|
||||
|
||||
SmoothedAnimation {
|
||||
target: playlistColumn; property: "width"
|
||||
|
||||
duration: VLCStyle.duration_fast
|
||||
easing.type: Easing.InSine
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
@ -301,7 +301,7 @@ FocusScope {
|
||||
//---------------------------------------------------------------------------------
|
||||
// Animations
|
||||
|
||||
Behavior on opacity { NumberAnimation { duration: 100 } }
|
||||
Behavior on opacity { NumberAnimation { duration: VLCStyle.duration_faster } }
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
@ -170,7 +170,7 @@ FocusScope {
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: 100
|
||||
duration: VLCStyle.duration_faster
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -330,7 +330,7 @@ FocusScope {
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: 100
|
||||
duration: VLCStyle.duration_faster
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -211,7 +211,7 @@ FocusScope {
|
||||
Behavior on width {
|
||||
SmoothedAnimation {
|
||||
easing.type: Easing.InSine
|
||||
duration: 10
|
||||
duration: VLCStyle.ms10
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -306,7 +306,7 @@ FocusScope {
|
||||
//---------------------------------------------------------------------------------
|
||||
// Animations
|
||||
|
||||
Behavior on opacity { NumberAnimation { duration: 100 } }
|
||||
Behavior on opacity { NumberAnimation { duration: VLCStyle.duration_faster } }
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
@ -277,7 +277,7 @@ FocusScope {
|
||||
//---------------------------------------------------------------------------------
|
||||
// Animations
|
||||
|
||||
Behavior on opacity { NumberAnimation { duration: 100 } }
|
||||
Behavior on opacity { NumberAnimation { duration: VLCStyle.duration_faster } }
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
@ -121,7 +121,7 @@ FocusScope {
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: 100
|
||||
duration: VLCStyle.duration_faster
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -83,7 +83,7 @@ Widgets.GridItem {
|
||||
|
||||
Behavior on newIndicatorMedian {
|
||||
NumberAnimation {
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
|
@ -208,7 +208,7 @@ FocusScope {
|
||||
|
||||
Behavior on rotation {
|
||||
NumberAnimation {
|
||||
duration: 100
|
||||
duration: VLCStyle.duration_faster
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -227,7 +227,7 @@ FocusScope {
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: 100
|
||||
duration: VLCStyle.duration_faster
|
||||
}
|
||||
}
|
||||
|
||||
@ -265,7 +265,7 @@ FocusScope {
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: 100
|
||||
duration: VLCStyle.duration_faster
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -61,7 +61,7 @@ AbstractButton {
|
||||
to: "*"
|
||||
|
||||
ColorAnimation {
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
properties: "foregroundColor,color"
|
||||
}
|
||||
}
|
||||
|
@ -239,7 +239,7 @@ Item{
|
||||
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: 75
|
||||
duration: VLCStyle.ms75
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
@ -317,7 +317,7 @@ Item{
|
||||
|
||||
Behavior on radius {
|
||||
NumberAnimation {
|
||||
duration: 75
|
||||
duration: VLCStyle.ms75
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
|
@ -55,7 +55,7 @@ T.Popup {
|
||||
property: "opacity"
|
||||
from: 0
|
||||
to: 1
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
pushExit: Transition {
|
||||
@ -63,7 +63,7 @@ T.Popup {
|
||||
property: "opacity"
|
||||
from: 1
|
||||
to: 0
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
popEnter: Transition {
|
||||
@ -71,7 +71,7 @@ T.Popup {
|
||||
property: "opacity"
|
||||
from: 0
|
||||
to: 1
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
popExit: Transition {
|
||||
@ -79,7 +79,7 @@ T.Popup {
|
||||
property: "opacity"
|
||||
from: 1
|
||||
to: 0
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -103,7 +103,7 @@ T.Popup {
|
||||
|
||||
Behavior on width {
|
||||
SmoothedAnimation {
|
||||
duration: 64
|
||||
duration: VLCStyle.ms64
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ FocusScope {
|
||||
id: animateExpand;
|
||||
target: root;
|
||||
properties: "implicitHeight"
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
easing.type: Easing.InSine
|
||||
to: VLCStyle.miniPlayerHeight
|
||||
onStopped: {
|
||||
@ -46,7 +46,7 @@ FocusScope {
|
||||
id: animateRetract;
|
||||
target: root;
|
||||
properties: "implicitHeight"
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
easing.type: Easing.OutSine
|
||||
to: 0
|
||||
onStopped: {
|
||||
|
@ -188,20 +188,20 @@ Slider {
|
||||
PropertyAnimation {
|
||||
from: 0.0
|
||||
to: bufferRect.bufferFrames
|
||||
duration: 2000
|
||||
duration: VLCStyle.ms2000
|
||||
easing.type: "OutBounce"
|
||||
}
|
||||
PauseAnimation {
|
||||
duration: 500
|
||||
duration: VLCStyle.ms500
|
||||
}
|
||||
PropertyAnimation {
|
||||
from: bufferRect.bufferFrames
|
||||
to: 0.0
|
||||
duration: 2000
|
||||
duration: VLCStyle.ms2000
|
||||
easing.type: "OutBounce"
|
||||
}
|
||||
PauseAnimation {
|
||||
duration: 500
|
||||
duration: VLCStyle.ms500
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -255,7 +255,14 @@ Slider {
|
||||
Transition {
|
||||
to: "hidden"
|
||||
SequentialAnimation {
|
||||
NumberAnimation { target: sliderHandle; properties: "implicitWidth,implicitHeight"; to: 0; duration: 150; easing.type: Easing.OutSine}
|
||||
NumberAnimation {
|
||||
target: sliderHandle; properties: "implicitWidth,implicitHeight"
|
||||
|
||||
to: 0
|
||||
|
||||
duration: VLCStyle.duration_fast; easing.type: Easing.OutSine
|
||||
}
|
||||
|
||||
PropertyAction { target: sliderHandle; property: "visible"; value: false; }
|
||||
}
|
||||
},
|
||||
@ -263,7 +270,14 @@ Slider {
|
||||
to: "visible"
|
||||
SequentialAnimation {
|
||||
PropertyAction { target: sliderHandle; property: "visible"; value: true; }
|
||||
NumberAnimation { target: sliderHandle; properties: "implicitWidth,implicitHeight"; to: VLCStyle.margin_small; duration: 150; easing.type: Easing.InSine}
|
||||
|
||||
NumberAnimation {
|
||||
target: sliderHandle; properties: "implicitWidth,implicitHeight"
|
||||
|
||||
to: VLCStyle.margin_small
|
||||
|
||||
duration: VLCStyle.duration_fast; easing.type: Easing.InSine
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
@ -481,11 +481,20 @@ FocusScope {
|
||||
}
|
||||
|
||||
add: Transition {
|
||||
NumberAnimation { property: "opacity"; from: 0; to: 1.0; duration: 200 }
|
||||
NumberAnimation {
|
||||
property: "opacity"; from: 0; to: 1.0
|
||||
|
||||
duration: VLCStyle.duration_normal
|
||||
}
|
||||
}
|
||||
|
||||
displaced: Transition {
|
||||
NumberAnimation { properties: "x,y"; duration: 200; easing.type: Easing.OutSine }
|
||||
NumberAnimation {
|
||||
properties: "x,y"
|
||||
|
||||
duration: VLCStyle.duration_normal; easing.type: Easing.OutSine
|
||||
}
|
||||
|
||||
NumberAnimation { property: "opacity"; to: 1.0 }
|
||||
}
|
||||
|
||||
|
@ -45,7 +45,7 @@ Rectangle {
|
||||
|
||||
property color activeBorderColor: VLCStyle.colors.bgFocus
|
||||
|
||||
property int animationDuration: 200
|
||||
property int animationDuration: VLCStyle.duration_normal
|
||||
|
||||
property bool backgroundAnimationRunning: false
|
||||
|
||||
|
@ -84,7 +84,7 @@ T.TabButton {
|
||||
|
||||
active: control.activeFocus
|
||||
|
||||
animationDuration: 140
|
||||
animationDuration: VLCStyle.ms140
|
||||
|
||||
backgroundColor: _getBackground()
|
||||
foregroundColor: _getForeground()
|
||||
|
@ -103,7 +103,7 @@ Item {
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
easing.type: Easing.InOutSine
|
||||
duration: 128
|
||||
duration: VLCStyle.ms128
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -18,6 +18,8 @@
|
||||
import QtQuick 2.11
|
||||
import QtQuick.Controls 2.4
|
||||
|
||||
import "qrc:///style/"
|
||||
|
||||
FocusScope {
|
||||
id: root
|
||||
|
||||
@ -92,15 +94,25 @@ FocusScope {
|
||||
Transition {
|
||||
to: "hidden"
|
||||
SequentialAnimation {
|
||||
NumberAnimation { target: container; property: toChange; duration: 150; easing.type: Easing.InSine}
|
||||
NumberAnimation {
|
||||
target: container; property: toChange
|
||||
|
||||
duration: VLCStyle.duration_fast; easing.type: Easing.InSine
|
||||
}
|
||||
|
||||
PropertyAction{ target: container; property: "visible" }
|
||||
}
|
||||
},
|
||||
Transition {
|
||||
to: "visible"
|
||||
SequentialAnimation {
|
||||
PropertyAction{ target: container; property: "visible" }
|
||||
NumberAnimation { target: container; property: toChange; duration: 150; easing.type: Easing.OutSine}
|
||||
PropertyAction { target: container; property: "visible" }
|
||||
|
||||
NumberAnimation {
|
||||
target: container; property: toChange
|
||||
|
||||
duration: VLCStyle.duration_fast; easing.type: Easing.OutSine
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
@ -622,7 +622,7 @@ FocusScope {
|
||||
target: root;
|
||||
properties: "_expandItemVerticalSpace"
|
||||
easing.type: Easing.OutQuad
|
||||
duration: 250
|
||||
duration: VLCStyle.duration_slow
|
||||
to: 0
|
||||
onStopped: {
|
||||
expandIndex = -1
|
||||
@ -638,7 +638,7 @@ FocusScope {
|
||||
target: root;
|
||||
properties: "_expandItemVerticalSpace"
|
||||
easing.type: Easing.InQuad
|
||||
duration: 250
|
||||
duration: VLCStyle.duration_slow
|
||||
from: 0
|
||||
}
|
||||
|
||||
@ -661,7 +661,7 @@ FocusScope {
|
||||
|
||||
function animateFlickableContentY( newContentY ) {
|
||||
animateContentY.stop()
|
||||
animateContentY.duration = 250
|
||||
animateContentY.duration = VLCStyle.duration_slow
|
||||
animateContentY.to = newContentY
|
||||
animateContentY.start()
|
||||
}
|
||||
|
@ -109,7 +109,7 @@ MouseArea {
|
||||
|
||||
NumberAnimation {
|
||||
properties: "opacity,playCoverOpacity"
|
||||
duration: 240
|
||||
duration: VLCStyle.duration_slow
|
||||
easing.type: Easing.InSine
|
||||
}
|
||||
|
||||
@ -132,7 +132,7 @@ MouseArea {
|
||||
|
||||
NumberAnimation {
|
||||
properties: "opacity,playCoverOpacity"
|
||||
duration: 200
|
||||
duration: VLCStyle.duration_normal
|
||||
easing.type: Easing.OutSine
|
||||
}
|
||||
|
||||
|
@ -253,7 +253,7 @@ FocusScope {
|
||||
transitions: Transition {
|
||||
NumberAnimation {
|
||||
property: "opacity"
|
||||
duration: 150
|
||||
duration: VLCStyle.duration_fast
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
@ -298,7 +298,7 @@ FocusScope {
|
||||
transitions: Transition {
|
||||
NumberAnimation {
|
||||
property: "opacity"
|
||||
duration: 150
|
||||
duration: VLCStyle.duration_fast
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
|
@ -335,7 +335,7 @@ Item {
|
||||
|
||||
NumberAnimation {
|
||||
property: "width"
|
||||
duration: 125
|
||||
duration: VLCStyle.ms125
|
||||
easing.type: Easing.InOutSine
|
||||
}
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ Rectangle {
|
||||
color: 'transparent'
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation { duration: 150; easing.type: Easing.OutQuad }
|
||||
NumberAnimation { duration: VLCStyle.duration_fast; easing.type: Easing.OutQuad }
|
||||
}
|
||||
|
||||
Image {
|
||||
|
@ -94,23 +94,23 @@ T.ProgressBar {
|
||||
NumberAnimation {
|
||||
from: - 1
|
||||
to: 1
|
||||
duration: 2000
|
||||
duration: VLCStyle.ms2000
|
||||
easing.type: Easing.OutBounce
|
||||
}
|
||||
|
||||
PauseAnimation {
|
||||
duration: 500
|
||||
duration: VLCStyle.ms500
|
||||
}
|
||||
|
||||
NumberAnimation {
|
||||
to: - 1
|
||||
from: 1
|
||||
duration: 2000
|
||||
duration: VLCStyle.ms2000
|
||||
easing.type: Easing.OutBounce
|
||||
}
|
||||
|
||||
PauseAnimation {
|
||||
duration: 500
|
||||
duration: VLCStyle.ms500
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -18,6 +18,8 @@
|
||||
import QtQuick 2.11
|
||||
import QtQuick.Controls 2.4
|
||||
|
||||
import "qrc:///style/"
|
||||
|
||||
Item {
|
||||
id: control
|
||||
|
||||
@ -39,7 +41,7 @@ Item {
|
||||
}
|
||||
|
||||
PauseAnimation {
|
||||
duration: 1000
|
||||
duration: VLCStyle.ms1000
|
||||
}
|
||||
|
||||
SmoothedAnimation {
|
||||
@ -53,7 +55,7 @@ Item {
|
||||
}
|
||||
|
||||
PauseAnimation {
|
||||
duration: 1000
|
||||
duration: VLCStyle.ms1000
|
||||
}
|
||||
|
||||
PropertyAction {
|
||||
|
@ -59,7 +59,7 @@ FocusScope {
|
||||
id: animateExpand;
|
||||
target: searchBoxRect;
|
||||
properties: "width"
|
||||
duration: 125
|
||||
duration: VLCStyle.ms125
|
||||
to: VLCStyle.widthSearchInput
|
||||
easing.type: Easing.InSine
|
||||
onStopped: {
|
||||
@ -71,7 +71,7 @@ FocusScope {
|
||||
id: animateRetract;
|
||||
target: searchBoxRect;
|
||||
properties: "width"
|
||||
duration: 125
|
||||
duration: VLCStyle.ms125
|
||||
to: 0
|
||||
easing.type: Easing.OutSine
|
||||
}
|
||||
|
@ -18,6 +18,8 @@
|
||||
import QtQuick 2.11
|
||||
import QtQuick.Controls 2.4
|
||||
|
||||
import "qrc:///style/"
|
||||
|
||||
/*
|
||||
* Custom StackView with brief transitions and helper to load view from the history
|
||||
*/
|
||||
@ -31,7 +33,7 @@ StackView {
|
||||
property: "opacity"
|
||||
from: 0.0
|
||||
to: 1.0
|
||||
duration: 250
|
||||
duration: VLCStyle.duration_slow
|
||||
easing.type: Easing.InSine
|
||||
}
|
||||
}
|
||||
@ -41,7 +43,7 @@ StackView {
|
||||
property: "opacity"
|
||||
from: 1.0
|
||||
to: 0.0
|
||||
duration: 250
|
||||
duration: VLCStyle.duration_slow
|
||||
easing.type: Easing.OutSine
|
||||
}
|
||||
}
|
||||
|
@ -43,7 +43,7 @@ Widgets.AnimatedBackground {
|
||||
|
||||
active: activeFocus
|
||||
|
||||
animationDuration: 140
|
||||
animationDuration: VLCStyle.ms140
|
||||
|
||||
backgroundColor: {
|
||||
if (delegate.selected)
|
||||
|
Loading…
Reference in New Issue
Block a user