qml add
This commit is contained in:
@@ -39,6 +39,8 @@ DISTFILES += \
|
||||
src/res/qml/audio_page/proximity/* \
|
||||
src/res/qml/audio_page/push_to_talk/* \
|
||||
src/res/qml/audio_page/profiles/* \
|
||||
src/res/qml/video_page/* \
|
||||
src/res/qml/video_page/dimmer/* \
|
||||
src/res/qml/common/* \
|
||||
|
||||
RC_FILE = src/res/icon.rc
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Layouts 1.3
|
||||
import ovras.advsettings 1.0
|
||||
import "../common"
|
||||
import "dimmer"
|
||||
|
||||
MyStackViewPage {
|
||||
headerText: "Motion Settings"
|
||||
|
||||
content: ColumnLayout {
|
||||
spacing: 18
|
||||
|
||||
DimmerGroupBox { id: dimmerGroupBox }
|
||||
|
||||
Item {
|
||||
Layout.fillHeight: true
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,104 @@
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Layouts 1.3
|
||||
import ovras.advsettings 1.0
|
||||
import "../../common"
|
||||
|
||||
GroupBox {
|
||||
id: dimmerGroupBox
|
||||
Layout.fillWidth: true
|
||||
|
||||
label: MyText {
|
||||
leftPadding: 10
|
||||
text: "Space Turn"
|
||||
bottomPadding: -10
|
||||
}
|
||||
background: Rectangle {
|
||||
color: "transparent"
|
||||
border.color: "#ffffff"
|
||||
radius: 8
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
|
||||
Rectangle {
|
||||
color: "#ffffff"
|
||||
height: 1
|
||||
Layout.fillWidth: true
|
||||
Layout.bottomMargin: 5
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
|
||||
MyToggleButton {
|
||||
id: turnBindLeft
|
||||
text: "Enable Left Hand"
|
||||
onCheckedChanged: {
|
||||
MoveCenterTabController.turnBindLeft = this.checked
|
||||
}
|
||||
}
|
||||
|
||||
MyToggleButton {
|
||||
id: turnBindRight
|
||||
text: "Enable Right Hand"
|
||||
onCheckedChanged: {
|
||||
MoveCenterTabController.turnBindRight = this.checked
|
||||
}
|
||||
}
|
||||
|
||||
Item {
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
||||
MyText {
|
||||
text: "Turn Comfort Mode:"
|
||||
horizontalAlignment: Text.AlignRight
|
||||
Layout.rightMargin: 10
|
||||
}
|
||||
|
||||
MySlider {
|
||||
id: turnComfortSlider
|
||||
from: 0
|
||||
to: 10
|
||||
stepSize: 1
|
||||
value: 0
|
||||
Layout.preferredWidth: 200
|
||||
Layout.alignment: Qt.AlignVCenter | Qt.AlignRight
|
||||
onValueChanged: {
|
||||
turnComfortText.text = turnComfortSlider.value
|
||||
MoveCenterTabController.turnComfortFactor = turnComfortSlider.value
|
||||
}
|
||||
}
|
||||
|
||||
MyText {
|
||||
id: turnComfortText
|
||||
text: "0"
|
||||
horizontalAlignment: Text.AlignRight
|
||||
Layout.preferredWidth: 30
|
||||
Layout.rightMargin: 10
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
turnBindLeft.checked = MoveCenterTabController.turnBindLeft
|
||||
turnBindRight.checked = MoveCenterTabController.turnBindRight
|
||||
turnComfortSlider.value = MoveCenterTabController.turnComfortFactor
|
||||
}
|
||||
|
||||
Connections {
|
||||
target: MoveCenterTabController
|
||||
|
||||
onTurnBindLeftChanged: {
|
||||
turnBindLeft.checked = MoveCenterTabController.turnBindLeft
|
||||
}
|
||||
onTurnBindRightChanged: {
|
||||
turnBindRight.checked = MoveCenterTabController.turnBindRight
|
||||
}
|
||||
onTurnComfortFactorChanged: {
|
||||
turnComfortSlider.value = MoveCenterTabController.turnComfortFactor
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ namespace advsettings
|
||||
{
|
||||
void VideoTabController::initStage1()
|
||||
{
|
||||
reloadVideoConfig();
|
||||
//reloadVideoConfig();
|
||||
}
|
||||
|
||||
//TODO args
|
||||
@@ -51,12 +51,11 @@ namespace advsettings
|
||||
}
|
||||
else
|
||||
{
|
||||
LOG(ERROR) << "Could not create ptt notification overlay: "
|
||||
LOG(ERROR) << "Could not create dimmer notification overlay: "
|
||||
<< vr::VROverlay()->GetOverlayErrorNameFromEnum(
|
||||
overlayError);
|
||||
}
|
||||
emit defaultProfileDisplay();
|
||||
*/
|
||||
//emit defaultProfileDisplay();
|
||||
}
|
||||
|
||||
void VideoTabController::eventLoopTick()
|
||||
|
||||
Reference in New Issue
Block a user