mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
better FAQ
This commit is contained in:
parent
7297ac9a09
commit
52c4d4fe69
4 changed files with 95 additions and 4 deletions
|
@ -34,6 +34,16 @@ Rectangle {
|
|||
}
|
||||
|
||||
|
||||
onActiveTabViewChanged: {
|
||||
for (var i = 0; i < tabListModel.count; i++) {
|
||||
if (tabListModel.get(i).tabViewName === activeTabView) {
|
||||
tabListView.currentIndex = i;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Rectangle {
|
||||
id: tabContainer
|
||||
anchors.top: parent.top
|
||||
|
@ -108,7 +118,6 @@ Rectangle {
|
|||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
tabListView.currentIndex = index;
|
||||
root.activeTabView = model.tabViewName;
|
||||
}
|
||||
}
|
||||
|
@ -134,6 +143,10 @@ Rectangle {
|
|||
id: faqTabViewContainer
|
||||
visible: activeTabView === "faqTabView"
|
||||
anchors.fill: parent
|
||||
|
||||
onSendToScript: {
|
||||
root.sendToScript(message);
|
||||
}
|
||||
}
|
||||
|
||||
HelpAbout.HelpAbout {
|
||||
|
|
|
@ -61,7 +61,7 @@ Item {
|
|||
}
|
||||
|
||||
HifiStylesUit.GraphikRegular {
|
||||
text: "You can find our frequently asked questions here:"
|
||||
text: "You can find answers to all of our frequently asked questions by clicking the button below."
|
||||
Layout.preferredWidth: parent.width
|
||||
Layout.preferredHeight: paintedHeight
|
||||
Layout.topMargin: 8
|
||||
|
@ -81,5 +81,40 @@ Item {
|
|||
Qt.openUrlExternally("https://www.highfidelity.com/knowledge");
|
||||
}
|
||||
}
|
||||
|
||||
HifiStylesUit.GraphikSemiBold {
|
||||
text: "Having problems with your audio?"
|
||||
Layout.preferredWidth: parent.width
|
||||
Layout.preferredHeight: paintedHeight
|
||||
Layout.topMargin: 32
|
||||
size: 16
|
||||
color: simplifiedUI.colors.text.white
|
||||
}
|
||||
|
||||
HifiStylesUit.GraphikRegular {
|
||||
text: "Quickly check your audio configuration and make changes to resolve any audio input/output issues."
|
||||
Layout.preferredWidth: parent.width
|
||||
Layout.preferredHeight: paintedHeight
|
||||
Layout.topMargin: 4
|
||||
size: 18
|
||||
wrapMode: Text.Wrap
|
||||
color: simplifiedUI.colors.text.white
|
||||
}
|
||||
|
||||
SimplifiedControls.Button {
|
||||
Layout.topMargin: 8
|
||||
width: 200
|
||||
height: 32
|
||||
text: "TEST YOUR AUDIO"
|
||||
|
||||
onClicked: {
|
||||
root.sendToScript({
|
||||
"source": "HelpApp.qml",
|
||||
"method": "goToAudioSettings"
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
signal sendToScript(var message);
|
||||
}
|
||||
|
|
|
@ -49,6 +49,15 @@ Rectangle {
|
|||
}
|
||||
}
|
||||
|
||||
onActiveTabViewChanged: {
|
||||
for (var i = 0; i < tabListModel.count; i++) {
|
||||
if (tabListModel.get(i).tabViewName === activeTabView) {
|
||||
tabListView.currentIndex = i;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
root.forceActiveFocus();
|
||||
}
|
||||
|
@ -138,7 +147,6 @@ Rectangle {
|
|||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
tabListView.currentIndex = index;
|
||||
root.activeTabView = model.tabViewName;
|
||||
}
|
||||
}
|
||||
|
@ -207,7 +215,24 @@ Rectangle {
|
|||
|
||||
|
||||
function fromScript(message) {
|
||||
if (message.source !== "simplifiedUI.js") {
|
||||
return;
|
||||
}
|
||||
|
||||
switch (message.method) {
|
||||
case "goToSettingsTab":
|
||||
var tabToGoTo = message.data.settingsTab;
|
||||
switch (tabToGoTo) {
|
||||
case "audio":
|
||||
activeTabView = "audioTabView";
|
||||
break;
|
||||
|
||||
default:
|
||||
console.log("A message was sent to the Settings window to change tabs, but an invalid tab was specified.");
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
console.log('SettingsApp.qml: Unrecognized message from JS');
|
||||
break;
|
||||
|
|
|
@ -188,6 +188,21 @@ function toggleSettingsApp() {
|
|||
}
|
||||
|
||||
|
||||
function handleGoToAudioSettings() {
|
||||
if (!settingsAppWindow) {
|
||||
toggleSettingsApp();
|
||||
}
|
||||
|
||||
settingsAppWindow.sendToQml({
|
||||
"source": "simplifiedUI.js",
|
||||
"method": "goToSettingsTab",
|
||||
"data": {
|
||||
"settingsTab": "audio"
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
var HELP_APP_MESSAGE_SOURCE = "HelpApp.qml";
|
||||
function onMessageFromHelpApp(message) {
|
||||
if (message.source !== HELP_APP_MESSAGE_SOURCE) {
|
||||
|
@ -195,7 +210,10 @@ function onMessageFromHelpApp(message) {
|
|||
}
|
||||
|
||||
switch (message.method) {
|
||||
|
||||
case "goToAudioSettings":
|
||||
handleGoToAudioSettings();
|
||||
break;
|
||||
|
||||
default:
|
||||
console.log("Unrecognized message from " + HELP_APP_MESSAGE_SOURCE + ": " + JSON.stringify(message));
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue