Rework seated-universe motion
This commit is contained in:
@@ -94,6 +94,7 @@ MyStackViewPage {
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: profileSection
|
||||
Layout.bottomMargin: 32
|
||||
spacing: 18
|
||||
RowLayout {
|
||||
@@ -504,7 +505,7 @@ MyStackViewPage {
|
||||
visible: false
|
||||
text: "Seated Recenter"
|
||||
onClicked: {
|
||||
MoveCenterTabController.updateSeatedResetData()
|
||||
MoveCenterTabController.sendSeatedRecenter()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -532,6 +533,7 @@ MyStackViewPage {
|
||||
offsetsGroupBox.visible = MoveCenterTabController.enableSeatedMotion
|
||||
rotationGroupBox.visible = MoveCenterTabController.enableSeatedMotion
|
||||
resetButtonRow.visible = MoveCenterTabController.enableSeatedMotion
|
||||
profileSection.visible = MoveCenterTabController.enableSeatedMotion
|
||||
seatedDisableWarningText.visible = !MoveCenterTabController.enableSeatedMotion
|
||||
|
||||
} else if (MoveCenterTabController.trackingUniverse === 1) {
|
||||
@@ -540,12 +542,14 @@ MyStackViewPage {
|
||||
offsetsGroupBox.visible = true
|
||||
rotationGroupBox.visible = true
|
||||
resetButtonRow.visible = true
|
||||
profileSection.visible = true
|
||||
seatedDisableWarningText.visible = false
|
||||
} else {
|
||||
spaceModeText.text = "Unknown(" + MoveCenterTabController.trackingUniverse + ")"
|
||||
offsetsGroupBox.visible = false
|
||||
rotationGroupBox.visible = false
|
||||
resetButtonRow.visible = false
|
||||
profileSection.visible = false
|
||||
seatedDisableWarningText.visible = false
|
||||
}
|
||||
reloadOffsetProfiles()
|
||||
@@ -588,6 +592,7 @@ MyStackViewPage {
|
||||
offsetsGroupBox.visible = MoveCenterTabController.enableSeatedMotion
|
||||
rotationGroupBox.visible = MoveCenterTabController.enableSeatedMotion
|
||||
resetButtonRow.visible = MoveCenterTabController.enableSeatedMotion
|
||||
profileSection.visible = MoveCenterTabController.enableSeatedMotion
|
||||
seatedDisableWarningText.visible = !MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
}
|
||||
@@ -598,6 +603,7 @@ MyStackViewPage {
|
||||
offsetsGroupBox.visible = MoveCenterTabController.enableSeatedMotion
|
||||
rotationGroupBox.visible = MoveCenterTabController.enableSeatedMotion
|
||||
resetButtonRow.visible = MoveCenterTabController.enableSeatedMotion
|
||||
profileSection.visible = MoveCenterTabController.enableSeatedMotion
|
||||
seatedDisableWarningText.visible = !MoveCenterTabController.enableSeatedMotion
|
||||
} else if (MoveCenterTabController.trackingUniverse === 1) {
|
||||
spaceModeText.text = "Standing"
|
||||
@@ -605,12 +611,14 @@ MyStackViewPage {
|
||||
offsetsGroupBox.visible = true
|
||||
rotationGroupBox.visible = true
|
||||
resetButtonRow.visible = true
|
||||
profileSection.visible = true
|
||||
seatedDisableWarningText.visible = false
|
||||
} else {
|
||||
spaceModeText.text = "Unknown(" + MoveCenterTabController.trackingUniverse + ")"
|
||||
offsetsGroupBox.visible = false
|
||||
rotationGroupBox.visible = false
|
||||
resetButtonRow.visible = false
|
||||
profileSection.visible = false
|
||||
seatedDisableWarningText.visible = false
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ MyStackViewPage {
|
||||
text: "Allow External App Chaperone Edits (Danger)"
|
||||
onCheckedChanged: {
|
||||
MoveCenterTabController.setAllowExternalEdits(checked, true)
|
||||
seatedOldExternalWarning.visible = checked && MoveCenterTabController.oldStyleMotion && MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,6 +32,7 @@ MyStackViewPage {
|
||||
text: "Old-Style Motion (per-frame disk writes)"
|
||||
onCheckedChanged: {
|
||||
MoveCenterTabController.setOldStyleMotion(checked, true)
|
||||
seatedOldExternalWarning.visible = MoveCenterTabController.allowExternalEdits && checked && MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,28 +49,10 @@ MyStackViewPage {
|
||||
text: "Enable Motion Features When in Seated Mode (Experimental)"
|
||||
onCheckedChanged: {
|
||||
MoveCenterTabController.setEnableSeatedMotion(checked, true)
|
||||
seatedOffsetsRecenterRow.visible = checked
|
||||
seatedOldExternalWarning.visible = MoveCenterTabController.allowExternalEdits && MoveCenterTabController.oldStyleMotion && checked
|
||||
}
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
id: seatedOffsetsRecenterRow
|
||||
|
||||
Item {
|
||||
Layout.preferredWidth: 50
|
||||
}
|
||||
|
||||
MyToggleButton {
|
||||
id: enableSeatedOffsetsRecenterToggle
|
||||
text: "Enable Auto-set Seated Offsets During Seated Recenter"
|
||||
onCheckedChanged: {
|
||||
MoveCenterTabController.setEnableSeatedOffsetsRecenter(checked, true)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
MyToggleButton {
|
||||
id: disableCrashRecoveryToggle
|
||||
text: "Disable Automatic Crash Recovery of Chaperone Config"
|
||||
@@ -165,6 +149,18 @@ MyStackViewPage {
|
||||
}
|
||||
}
|
||||
|
||||
MyText {
|
||||
id: seatedOldExternalWarning
|
||||
wrapMode: Text.WordWrap
|
||||
font.pointSize: 20
|
||||
color: "#FFA500"
|
||||
text: "WARNING: 'Allow External App Chaperone Edits' + 'Old-Style Motion' + 'Enable Motion Features When in Seated Mode' active together may cause space center misalignment. Load the «Autosaved Profile» in the 'Chaperone' tab to fix."
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
Layout.leftMargin: 20
|
||||
Layout.rightMargin: 20
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
||||
Item {
|
||||
Layout.fillHeight: true
|
||||
}
|
||||
@@ -176,9 +172,7 @@ MyStackViewPage {
|
||||
allowExternalEditsToggle.checked = MoveCenterTabController.allowExternalEdits
|
||||
oldStyleMotionToggle.checked = MoveCenterTabController.oldStyleMotion
|
||||
universeCenteredRotationToggle.checked = MoveCenterTabController.universeCenteredRotation
|
||||
enableSeatedOffsetsRecenterToggle.checked = MoveCenterTabController.enableSeatedOffsetsRecenter
|
||||
enableSeatedMotionToggle.checked = MoveCenterTabController.enableSeatedMotion
|
||||
seatedOffsetsRecenterRow.visible = MoveCenterTabController.enableSeatedMotion
|
||||
|
||||
disableCrashRecoveryToggle.checked = OverlayController.crashRecoveryDisabled
|
||||
customTickRateText.text = OverlayController.customTickRateMs
|
||||
@@ -187,6 +181,9 @@ MyStackViewPage {
|
||||
customTickRateLabel.visible = vsyncDisabledToggle.checked
|
||||
customTickRateMsLabel.visible = vsyncDisabledToggle.checked
|
||||
debugStateRow.visible = OverlayController.enableDebug
|
||||
debugStateText.text = OverlayController.debugState
|
||||
|
||||
seatedOldExternalWarning.visible = MoveCenterTabController.allowExternalEdits && MoveCenterTabController.oldStyleMotion && MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
|
||||
Connections {
|
||||
@@ -200,19 +197,18 @@ MyStackViewPage {
|
||||
target: MoveCenterTabController
|
||||
onAllowExternalEditsChanged: {
|
||||
allowExternalEditsToggle.checked = MoveCenterTabController.allowExternalEdits
|
||||
seatedOldExternalWarning.visible = MoveCenterTabController.allowExternalEdits && MoveCenterTabController.oldStyleMotion && MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
onOldStyleMotionChanged: {
|
||||
oldStyleMotionToggle.checked = MoveCenterTabController.oldStyleMotion
|
||||
seatedOldExternalWarning.visible = MoveCenterTabController.allowExternalEdits && MoveCenterTabController.oldStyleMotion && MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
onUniverseCenteredRotationChanged: {
|
||||
universeCenteredRotationToggle.checked = MoveCenterTabController.universeCenteredRotation
|
||||
}
|
||||
onEnableSeatedOffsetsRecenterChanged: {
|
||||
enableSeatedOffsetsRecenterToggle.checked = MoveCenterTabController.enableSeatedOffsetsRecenter
|
||||
}
|
||||
onEnableSeatedMotionChanged: {
|
||||
enableSeatedMotionToggle.checked = MoveCenterTabController.enableSeatedMotion
|
||||
seatedOffsetsRecenterRow.visible = MoveCenterTabController.enableSeatedMotion
|
||||
seatedOldExternalWarning.visible = MoveCenterTabController.allowExternalEdits && MoveCenterTabController.oldStyleMotion && MoveCenterTabController.enableSeatedMotion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -235,6 +231,10 @@ MyStackViewPage {
|
||||
onEnableDebugChanged: {
|
||||
debugStateRow.visible = OverlayController.enableDebug
|
||||
}
|
||||
|
||||
onDebugStateChanged: {
|
||||
debugStateText.text = OverlayController.debugState
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user