Commit e845de42 authored by Jacob DeWitt's avatar Jacob DeWitt Committed by Commit Bot

Change 'grip' to 'squeeze' for XRInputSource.profiles

This makes the values up to date with the webxr-input-profiles registry
values as https://github.com/immersive-web/webxr-input-profiles/pull/91
has been completed.

Bug: 992631
Change-Id: I98677777d47710a83fbd91ad56bda6017134af9b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1816731
Auto-Submit: Jacob DeWitt <jacde@chromium.org>
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
Reviewed-by: default avatarAlexander Cooper <alcooper@chromium.org>
Cr-Commit-Position: refs/heads/master@{#698918}
parent 3329fdba
......@@ -557,8 +557,8 @@ IN_PROC_MULTI_CLASS_BROWSER_TEST_F2(WebXrVrOpenVrBrowserTest,
// only supports that type of controller and fills in default values if
// those inputs don't exist.
VerifyInputSourceProfilesArray(
t,
{"windows-mixed-reality", "generic-trigger-grip-touchpad-thumbstick"});
t, {"windows-mixed-reality",
"generic-trigger-squeeze-touchpad-thumbstick"});
} else if (t->GetRuntimeType() ==
XrBrowserTestBase::RuntimeType::RUNTIME_OPENVR) {
VerifyInputSourceProfilesArray(
......@@ -633,8 +633,8 @@ IN_PROC_MULTI_CLASS_BROWSER_TEST_F2(WebXrVrOpenVrBrowserTest,
// only supports that type of controller and fills in default values if
// those inputs don't exist.
VerifyInputSourceProfilesArray(
t,
{"windows-mixed-reality", "generic-trigger-grip-touchpad-thumbstick"});
t, {"windows-mixed-reality",
"generic-trigger-squeeze-touchpad-thumbstick"});
} else if (t->GetRuntimeType() ==
XrBrowserTestBase::RuntimeType::RUNTIME_OPENVR) {
VerifyInputSourceProfilesArray(
......@@ -738,13 +738,13 @@ IN_PROC_MULTI_CLASS_BROWSER_TEST_F2(WebXrVrOpenVrBrowserTest,
// only supports that type of controller and fills in default values if
// those inputs don't exist.
VerifyInputSourceProfilesArray(
t,
{"windows-mixed-reality", "generic-trigger-grip-touchpad-thumbstick"});
t, {"windows-mixed-reality",
"generic-trigger-squeeze-touchpad-thumbstick"});
} else if (t->GetRuntimeType() ==
XrBrowserTestBase::RuntimeType::RUNTIME_OPENVR) {
VerifyInputSourceProfilesArray(
t,
{"test-value-test-value", "generic-trigger-grip-touchpad-thumbstick"});
t, {"test-value-test-value",
"generic-trigger-squeeze-touchpad-thumbstick"});
}
t->RunJavaScriptOrFail("done()");
......@@ -903,7 +903,7 @@ IN_PROC_BROWSER_TEST_F(WebXrVrOpenVrBrowserTest, TestGamepadOptionalData) {
PollJavaScriptBooleanOrFail("isButtonCountEqualTo(3)", kPollTimeoutShort);
VerifyInputSourceProfilesArray(
this, {"test-value-test-value", "generic-trigger-grip-touchpad"});
this, {"test-value-test-value", "generic-trigger-squeeze-touchpad"});
RunJavaScriptOrFail("done()");
EndTest();
......
......@@ -368,7 +368,7 @@ device::mojom::XRInputSourceStatePtr OculusRenderLoop::GetTouchData(
// The absence of "touchpad" in this string indicates that the slots in the
// button and axes arrays are placeholders required by the xr-standard mapping
// but not actually updated with any input.
desc->profiles.push_back("generic-trigger-grip-thumbstick");
desc->profiles.push_back("generic-trigger-squeeze-thumbstick");
state->description = std::move(desc);
......
......@@ -355,7 +355,7 @@ class OpenVRGamepadBuilder : public XRStandardGamepadBuilder {
// trigger if we get here.
std::string capabilities = "generic-trigger";
if (HasSecondaryButton()) {
capabilities += "-grip";
capabilities += "-squeeze";
}
if (HasTouchpad()) {
capabilities += "-touchpad";
......
......@@ -575,7 +575,8 @@ ParsedInputState MixedRealityInputHelper::ParseWindowsSourceState(
// This makes it clear that the controller actually has a grip button and
// touchpad and thumbstick input. Otherwise, it's ambiguous whether slots
// like the touchpad buttons + axes are hooked up vs just placeholders.
description->profiles.push_back("generic-trigger-grip-touchpad-thumbstick");
description->profiles.push_back(
"generic-trigger-squeeze-touchpad-thumbstick");
source_state->gamepad = GetWebXRGamepad(input_state);
} else {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment