diff --git a/docs/screenshots/AudioPage.png b/docs/screenshots/AudioPage.png index eedc31c..f0f5342 100644 Binary files a/docs/screenshots/AudioPage.png and b/docs/screenshots/AudioPage.png differ diff --git a/src/res/qml/audio_page/profiles/ProfileButtons.qml b/src/res/qml/audio_page/profiles/ProfileButtons.qml index b7c3d84..ca9c48d 100644 --- a/src/res/qml/audio_page/profiles/ProfileButtons.qml +++ b/src/res/qml/audio_page/profiles/ProfileButtons.qml @@ -10,18 +10,10 @@ ColumnLayout { id: audioMessageDialog } - PttDeleteProfileDialog { - id: pttDeleteProfileDialog - } - AudioDeleteProfileDialog { id: audioDeleteProfileDialog } - PttNewProfileDialog { - id: pttNewProfileDialog - } - AudioNewProfileDialog { id: audioNewProfileDialog } @@ -61,38 +53,9 @@ ColumnLayout { } } } - MyText { - text: "PTT Profile:" - Layout.preferredWidth: 150 - } - - MyComboBox { - id: pttProfileComboBox - Layout.preferredWidth: 250 - model: [""] - onCurrentIndexChanged: { - if (currentIndex > 0) { - pttApplyProfileButton.enabled = true - pttDeleteProfileButton.enabled = true - } else { - pttApplyProfileButton.enabled = false - pttDeleteProfileButton.enabled = false - } - } - } - - MyPushButton { - id: pttApplyProfileButton - enabled: true - Layout.preferredWidth: 150 - text: "Apply" - onClicked: { - if (pttProfileComboBox.currentIndex > 0) { - AudioTabController.applyPttProfile( - pttProfileComboBox.currentIndex - 1) - } - } + // Text continues in next RowLayout. + text: "Change the Push To Talk settings" } } RowLayout { @@ -117,62 +80,27 @@ ColumnLayout { audioNewProfileDialog.openPopup() } } - Item { - Layout.fillWidth: true - } - MyPushButton { - id: pttDeleteProfileButton - enabled: true - Layout.preferredWidth: 200 - text: "Delete Profile" - onClicked: { - if (pttProfileComboBox.currentIndex > 0) { - pttDeleteProfileDialog.profileIndex = pttProfileComboBox.currentIndex - 1 - pttDeleteProfileDialog.open() - } - } - } - MyPushButton { - Layout.preferredWidth: 200 - text: "New Profile" - onClicked: { - pttNewProfileDialog.openPopup() - } + MyText { + // Text continues from RowLayout above. + text: "\t\tin the SteamVR bindings menu." } } Component.onCompleted: { - reloadPttProfiles() reloadAudioProfiles() } Connections { target: AudioTabController - onPttProfilesUpdated: { - reloadPttProfiles() - } onAudioProfilesUpdated: { reloadAudioProfiles() } onAudioProfileAdded: { audioProfileComboBox.currentIndex = AudioTabController.getAudioProfileCount() } - onPttProfileAdded: { - pttProfileComboBox.currentIndex = AudioTabController.getPttProfileCount() - } onDefaultProfileDisplay: { audioProfileComboBox.currentIndex = AudioTabController.getDefaultAudioProfileIndex( ) + 1 } } - function reloadPttProfiles() { - var profiles = [""] - var profileCount = AudioTabController.getPttProfileCount() - for (var i = 0; i < profileCount; i++) { - profiles.push(AudioTabController.getPttProfileName(i)) - } - pttProfileComboBox.currentIndex = 0 - pttProfileComboBox.model = profiles - } - function reloadAudioProfiles() { var profiles = [""] var profileCount = AudioTabController.getAudioProfileCount() diff --git a/src/res/qml/audio_page/push_to_talk/PttButtons.qml b/src/res/qml/audio_page/push_to_talk/PttButtons.qml index 37e84e6..d8eaf3d 100644 --- a/src/res/qml/audio_page/push_to_talk/PttButtons.qml +++ b/src/res/qml/audio_page/push_to_talk/PttButtons.qml @@ -6,6 +6,7 @@ import "../../common" ColumnLayout { RowLayout { + Layout.fillWidth: true PttControllerConfigDialog { id: pttControllerConfigDialog pttControllerConfigClass: AudioTabController @@ -13,47 +14,16 @@ ColumnLayout { MyToggleButton { id: audioPttEnabledToggle - Layout.preferredWidth: 260 + //Layout.preferredWidth: 260 + Layout.fillWidth: true text: "Push-to-Talk:" onClicked: { AudioTabController.pttEnabled = checked } } - MyToggleButton { - id: audioPttLeftControllerToggle - text: "Left Controller" - onClicked: { - AudioTabController.setPttLeftControllerEnabled(checked, false) - } - } - MyPushButton { - text: "Configure" - onClicked: { - pttControllerConfigDialog.openPopup(0) - } - } - Item { - Layout.fillWidth: true - } - MyToggleButton { - id: audioPttRightControllerToggle - text: "Right Controller" - onClicked: { - AudioTabController.setPttRightControllerEnabled(checked, false) - } - } - MyPushButton { - text: "Configure" - onClicked: { - pttControllerConfigDialog.openPopup(1) - } - } - } - RowLayout { - MyToggleButton { id: audioPttShowNotificationToggle - Layout.leftMargin: 350 + Layout.fillWidth: true text: "Show notification in HMD" onCheckedChanged: { AudioTabController.setPttShowNotification(checked, false) @@ -61,7 +31,7 @@ ColumnLayout { } MyToggleButton { id: audioPttReverseToggle - Layout.leftMargin: 118 + Layout.fillWidth: true text: "Push-to-Mute" onClicked: { AudioTabController.setMicReversePtt(checked, false) @@ -71,8 +41,6 @@ ColumnLayout { Component.onCompleted: { audioPttEnabledToggle.checked = AudioTabController.pttEnabled - audioPttLeftControllerToggle.checked = AudioTabController.pttLeftControllerEnabled - audioPttRightControllerToggle.checked = AudioTabController.pttRightControllerEnabled audioPttShowNotificationToggle.checked = AudioTabController.pttShowNotification audioPttReverseToggle.checked = AudioTabController.micReversePtt } @@ -81,12 +49,6 @@ ColumnLayout { onPttEnabledChanged: { audioPttEnabledToggle.checked = AudioTabController.pttEnabled } - onPttLeftControllerEnabledChanged: { - audioPttLeftControllerToggle.checked = AudioTabController.pttLeftControllerEnabled - } - onPttRightControllerEnabledChanged: { - audioPttRightControllerToggle.checked = AudioTabController.pttRightControllerEnabled - } onMicReversePttChanged: { audioPttReverseToggle.checked = AudioTabController.micReversePtt }