1
0
mirror of https://gitlab.com/kelteseth/ScreenPlay.git synced 2024-09-18 08:22:33 +02:00
ScreenPlay/ScreenPlayWorkshop/qml/SteamWorkshop.qml

81 lines
2.0 KiB
QML
Raw Normal View History

import QtQuick
import QtQuick.Controls
import QtQuick.Controls.Material
2021-07-15 12:07:39 +02:00
import Qt5Compat.GraphicalEffects
import QtQuick.Layouts
import ScreenPlayWorkshop
import WorkshopEnums
2021-06-25 12:07:28 +02:00
import "upload/"
Item {
id: root
property Item modalSource
2022-01-16 12:22:57 +01:00
ScreenPlayWorkshop {
id: screenPlayWorkshop
Component.onCompleted: {
if (screenPlayWorkshop.init()) {
stackView.push("qrc:/qml/ScreenPlayWorkshop/qml/SteamWorkshopStartPage.qml", {
2023-02-02 15:25:26 +01:00
"stackView": stackView,
"screenPlayWorkshop": screenPlayWorkshop,
"steamWorkshop": screenPlayWorkshop.steamWorkshop,
"background": background
});
} else {
2023-02-02 15:25:26 +01:00
popupOffline.open();
}
2021-06-25 12:07:28 +02:00
}
}
Background {
id: background
anchors.fill: parent
stackViewDepth: stackView.depth
2021-06-25 12:07:28 +02:00
}
PopupOffline {
id: popupOffline
workshop: screenPlayWorkshop
steam: screenPlayWorkshop.steamWorkshop
2022-01-16 12:22:57 +01:00
modalSource: root.modalSource
2021-06-25 12:07:28 +02:00
}
StackView {
id: stackView
property int duration: 300
anchors.fill: parent
replaceEnter: Transition {
OpacityAnimator {
from: 0
to: 1
duration: stackView.duration
easing.type: Easing.InOutQuart
2021-06-25 12:07:28 +02:00
}
ScaleAnimator {
from: 0.8
to: 1
duration: stackView.duration
easing.type: Easing.InOutQuart
2021-06-25 12:07:28 +02:00
}
}
replaceExit: Transition {
OpacityAnimator {
from: 1
to: 0
duration: stackView.duration
2021-06-25 12:07:28 +02:00
easing.type: Easing.InOutQuart
}
ScaleAnimator {
from: 1
to: 0.8
duration: stackView.duration
easing.type: Easing.InOutQuart
}
2021-06-25 12:07:28 +02:00
}
}
}