Adding check for WindowsMR to the showHelp menu

This commit is contained in:
Wayne Chen 2018-07-11 11:56:14 -07:00
parent f7e906440f
commit 179ba6506e
2 changed files with 13 additions and 13 deletions

View file

@ -72,10 +72,6 @@
document.getElementById("main_image").setAttribute("src", "img/tablet-help-keyboard.jpg");
}
function showWindowsMR() {
document.getElementById("main_image").setAttribute("src", "img/tablet-help-windowsMR.jpg");
}
function showHandControllers() {
document.getElementById("main_image").setAttribute("src", handControllerImageURL);
}
@ -106,10 +102,11 @@
showHandControllers();
break;
case 2:
showGamepad();
handControllerImageURL = "img/tablet-help-windowsMR.jpg";
showHandControllers();
break;
case 3:
showWindowsMR();
showGamepad();
break;
case 4:
showKbm();
@ -151,33 +148,33 @@
handControllerImageURL = "img/tablet-help-oculus.jpg";
index = 0;
break;
case "windowsMR":
handControllerImageURL = "img/tablet-help-windowsMR.jpg";
index = 2;
break;
case "vive":
default:
handControllerImageURL = "img/tablet-help-vive.jpg";
index = 1;
}
print("here");
switch (params.defaultTab) {
case "gamepad":
showGamepad();
index = 2;
index = 3;
break;
case "handControllers":
showHandControllers();
break;
case "windowsMR":
showWindowsMR();
index = 3;
break;
case "kbm":
default:
showKbm();
index = 4;
}
print("here3");
}
</script>
</head>

View file

@ -3238,6 +3238,9 @@ void Application::showHelp() {
} else if (PluginUtils::isOculusTouchControllerAvailable()) {
defaultTab = TAB_HAND_CONTROLLERS;
handControllerName = HAND_CONTROLLER_NAME_OCULUS_TOUCH;
} else if (qApp->getActiveDisplayPlugin()->getName() == "WindowMS") {
defaultTab = TAB_HAND_CONTROLLERS;
handControllerName = HAND_CONTROLLER_NAME_WINDOWS_MR;
} else if (PluginUtils::isXboxControllerAvailable()) {
defaultTab = TAB_GAMEPAD;
}