mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 10:00:18 +02:00
Duration and timing controls are disabled when event is not time based
This commit is contained in:
parent
648e6a6c9b
commit
ef63651b2b
1 changed files with 8 additions and 1 deletions
|
@ -72,6 +72,8 @@ Rectangle {
|
||||||
interval: 100; running: false; repeat: false
|
interval: 100; running: false; repeat: false
|
||||||
onTriggered: {
|
onTriggered: {
|
||||||
paramWidgetLoader.sourceComponent = paramWidgets
|
paramWidgetLoader.sourceComponent = paramWidgets
|
||||||
|
var isTimeBased = categoryBox.currentIndex==0 || categoryBox.currentIndex==3
|
||||||
|
paramWidgetLoader.item.isTimeBased = isTimeBased
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
onCurrentIndexChanged: {
|
onCurrentIndexChanged: {
|
||||||
|
@ -82,6 +84,7 @@ Rectangle {
|
||||||
"Time based threshold, gradients centered on bottom of object",
|
"Time based threshold, gradients centered on bottom of object",
|
||||||
"UNSUPPORTED"
|
"UNSUPPORTED"
|
||||||
]
|
]
|
||||||
|
|
||||||
description.text = descriptions[currentIndex]
|
description.text = descriptions[currentIndex]
|
||||||
root.config["editedCategory"] = currentIndex;
|
root.config["editedCategory"] = currentIndex;
|
||||||
// This is a hack to be sure the widgets below properly reflect the change of category: delete the Component
|
// This is a hack to be sure the widgets below properly reflect the change of category: delete the Component
|
||||||
|
@ -166,7 +169,7 @@ Rectangle {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: 3
|
spacing: 3
|
||||||
width: root_col.width
|
width: root_col.width
|
||||||
|
property bool isTimeBased
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -327,6 +330,8 @@ Rectangle {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
|
enabled: isTimeBased
|
||||||
|
opacity: isTimeBased ? 1.0 : 0.0
|
||||||
anchors.left: undefined
|
anchors.left: undefined
|
||||||
anchors.right: undefined
|
anchors.right: undefined
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -339,6 +344,8 @@ Rectangle {
|
||||||
min: 0.1
|
min: 0.1
|
||||||
}
|
}
|
||||||
HifiControls.ComboBox {
|
HifiControls.ComboBox {
|
||||||
|
enabled: isTimeBased
|
||||||
|
opacity: isTimeBased ? 1.0 : 0.0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
model: ["Linear", "Ease In", "Ease Out", "Ease In / Out"]
|
model: ["Linear", "Ease In", "Ease Out", "Ease In / Out"]
|
||||||
currentIndex: root.config["timing"]
|
currentIndex: root.config["timing"]
|
||||||
|
|
Loading…
Reference in a new issue