| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298 |
- // Copyright (C) 2022 The Qt Company Ltd.
- // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
- import QtQuick 2.15
- import QtQuick.Layouts 1.15
- import HelperWidgets 2.0
- import StudioTheme 1.0 as StudioTheme
- Column {
- width: parent.width
- Section {
- width: parent.width
- caption: qsTr("WASD Controller")
- SectionLayout {
- PropertyLabel {
- text: qsTr("Controlled Node")
- tooltip: qsTr("Sets the 3D node controlled by this controller.")
- }
- SecondColumnLayout {
- ItemFilterComboBox {
- typeFilter: "QtQuick3D.Node"
- backendValue: backendValues.controlledObject
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Invert X")
- tooltip: qsTr("Enables inverting X-axis controls.")
- }
- SecondColumnLayout {
- CheckBox {
- text: qsTr("Enabled")
- backendValue: backendValues.xInvert
- implicitWidth: StudioTheme.Values.twoControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Invert Y")
- tooltip: qsTr("Enables inverting Y-axis controls.")
- }
- SecondColumnLayout {
- CheckBox {
- text: qsTr("Enabled")
- backendValue: backendValues.yInvert
- implicitWidth: StudioTheme.Values.twoControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Mouse Control")
- tooltip: qsTr("Enables using mouse to control the target node.")
- }
- SecondColumnLayout {
- CheckBox {
- text: qsTr("Enabled")
- backendValue: backendValues.mouseEnabled
- implicitWidth: StudioTheme.Values.twoControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Keyboard Control")
- tooltip: qsTr("Enables using keyboard to control the target node.")
- }
- SecondColumnLayout {
- CheckBox {
- text: qsTr("Enabled")
- backendValue: backendValues.keysEnabled
- implicitWidth: StudioTheme.Values.twoControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- // TODO: acceptedButtons has no control as there is currently no support for a flags
- // type of property control in QDS.
- }
- }
- Section {
- width: parent.width
- caption: qsTr("Speeds")
- SectionLayout {
- PropertyLabel {
- text: qsTr("Speed")
- tooltip: qsTr("Sets the general navigation speed multiplier.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.speed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Shift Speed")
- tooltip: qsTr("Sets the navigation speed multiplier when the Shift key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.shiftSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Forward Speed")
- tooltip: qsTr("Sets the navigation speed when forward key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.forwardSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Back Speed")
- tooltip: qsTr("Sets the navigation speed when back key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.backSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Right Speed")
- tooltip: qsTr("Sets the navigation speed when right key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.rightSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Left Speed")
- tooltip: qsTr("Sets the navigation speed when left key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.leftSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Up Speed")
- tooltip: qsTr("Sets the navigation speed when up key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.upSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Down Speed")
- tooltip: qsTr("Sets the navigation speed when down key is pressed.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.downSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("X Speed")
- tooltip: qsTr("Sets the navigation speed when mouse is moved along X-axis.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.xSpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- PropertyLabel {
- text: qsTr("Y Speed")
- tooltip: qsTr("Sets the navigation speed when mouse is moved along Y-axis.")
- }
- SecondColumnLayout {
- SpinBox {
- minimumValue: 0
- maximumValue: 999999
- decimals: 2
- stepSize: 0.1
- backendValue: backendValues.ySpeed
- implicitWidth: StudioTheme.Values.singleControlColumnWidth
- + StudioTheme.Values.actionIndicatorWidth
- }
- ExpandingSpacer {}
- }
- }
- }
- }
|