Skip to content

Commit 22312cd

Browse files
[XR] Proposal to hide legacy XR HMD/controllers layout in Editor UI dropdowns (#1565)
* proposal to hide legacy XR controllers layout in Editor UI dropdowns * add changelog item
1 parent 67e120a commit 22312cd

File tree

5 files changed

+18
-17
lines changed

5 files changed

+18
-17
lines changed

Packages/com.unity.inputsystem/CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ however, it has to be formatted properly to pass verification tests.
1111
## [Unreleased]
1212

1313
### Changed
14-
- Readded OnDisable() member to MultiplayerEventSystem which was previously removed from the API
14+
- Readded OnDisable() member to MultiplayerEventSystem which was previously removed from the API.
15+
- Hide XR legacy HMD and controllers layouts from Editor UI dropdown.
1516

1617
### Fixed
1718
- Fix UI sometimes ignoring the first mouse click event after losing and regaining focus ([case ISXB-127](https://issuetracker.unity3d.com/product/unity/issues/guid/ISXB-127).

Packages/com.unity.inputsystem/InputSystem/Plugins/XR/Devices/GoogleVR.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ namespace Unity.XR.GoogleVr
1010
/// <summary>
1111
/// A head-mounted display powered by Google Daydream.
1212
/// </summary>
13-
[InputControlLayout(displayName = "Daydream Headset")]
13+
[InputControlLayout(displayName = "Daydream Headset", hideInUI = true)]
1414
public class DaydreamHMD : XRHMD
1515
{
1616
}
1717

1818
/// <summary>
1919
/// An XR controller powered by Google Daydream.
2020
/// </summary>
21-
[InputControlLayout(displayName = "Daydream Controller", commonUsages = new[] { "LeftHand", "RightHand" })]
21+
[InputControlLayout(displayName = "Daydream Controller", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
2222
public class DaydreamController : XRController
2323
{
2424
[InputControl]

Packages/com.unity.inputsystem/InputSystem/Plugins/XR/Devices/Oculus.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace Unity.XR.Oculus.Input
1111
/// <summary>
1212
/// An Oculus VR headset (such as the Oculus Rift series of devices).
1313
/// </summary>
14-
[InputControlLayout(displayName = "Oculus Headset")]
14+
[InputControlLayout(displayName = "Oculus Headset", hideInUI = true)]
1515
public class OculusHMD : XRHMD
1616
{
1717
[InputControl]
@@ -67,7 +67,7 @@ protected override void FinishSetup()
6767
/// <summary>
6868
/// An Oculus Touch controller.
6969
/// </summary>
70-
[InputControlLayout(displayName = "Oculus Touch Controller", commonUsages = new[] { "LeftHand", "RightHand" })]
70+
[InputControlLayout(displayName = "Oculus Touch Controller", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
7171
public class OculusTouchController : XRControllerWithRumble
7272
{
7373
[InputControl(aliases = new[] { "Primary2DAxis", "Joystick" })]
@@ -156,7 +156,7 @@ protected override void FinishSetup()
156156
/// <summary>
157157
/// An Oculus Remote controller.
158158
/// </summary>
159-
[InputControlLayout(displayName = "Oculus Remote")]
159+
[InputControlLayout(displayName = "Oculus Remote", hideInUI = true)]
160160
public class OculusRemote : InputDevice
161161
{
162162
[InputControl]
@@ -179,7 +179,7 @@ protected override void FinishSetup()
179179
/// <summary>
180180
/// A Standalone VR headset that includes on-headset controls.
181181
/// </summary>
182-
[InputControlLayout(displayName = "Oculus Headset (w/ on-headset controls)")]
182+
[InputControlLayout(displayName = "Oculus Headset (w/ on-headset controls)", hideInUI = true)]
183183
public class OculusHMDExtended : OculusHMD
184184
{
185185
[InputControl]
@@ -199,7 +199,7 @@ protected override void FinishSetup()
199199
/// <summary>
200200
/// A Gear VR controller.
201201
/// </summary>
202-
[InputControlLayout(displayName = "GearVR Controller", commonUsages = new[] { "LeftHand", "RightHand" })]
202+
[InputControlLayout(displayName = "GearVR Controller", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
203203
public class GearVRTrackedController : XRController
204204
{
205205
[InputControl]

Packages/com.unity.inputsystem/InputSystem/Plugins/XR/Devices/OpenVR.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
namespace Unity.XR.OpenVR
1010
{
11-
[InputControlLayout(displayName = "OpenVR Headset")]
11+
[InputControlLayout(displayName = "OpenVR Headset", hideInUI = true)]
1212
public class OpenVRHMD : XRHMD
1313
{
1414
[InputControl(noisy = true)]
@@ -43,7 +43,7 @@ protected override void FinishSetup()
4343
}
4444
}
4545

46-
[InputControlLayout(displayName = "Windows MR Controller (OpenVR)", commonUsages = new[] { "LeftHand", "RightHand" })]
46+
[InputControlLayout(displayName = "Windows MR Controller (OpenVR)", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
4747
public class OpenVRControllerWMR : XRController
4848
{
4949
[InputControl(noisy = true)]
@@ -96,7 +96,7 @@ protected override void FinishSetup()
9696
/// <summary>
9797
/// An HTC Vive Wand controller.
9898
/// </summary>
99-
[InputControlLayout(displayName = "Vive Wand", commonUsages = new[] { "LeftHand", "RightHand" })]
99+
[InputControlLayout(displayName = "Vive Wand", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
100100
public class ViveWand : XRControllerWithRumble
101101
{
102102
[InputControl]
@@ -142,7 +142,7 @@ protected override void FinishSetup()
142142
/// <summary>
143143
/// An HTC Vive lighthouse.
144144
/// </summary>
145-
[InputControlLayout(displayName = "Vive Lighthouse")]
145+
[InputControlLayout(displayName = "Vive Lighthouse", hideInUI = true)]
146146
public class ViveLighthouse : TrackedDevice
147147
{
148148
}
@@ -167,7 +167,7 @@ protected override void FinishSetup()
167167
}
168168
}
169169

170-
[InputControlLayout(displayName = "Handed Vive Tracker", commonUsages = new[] { "LeftHand", "RightHand" })]
170+
[InputControlLayout(displayName = "Handed Vive Tracker", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
171171
public class HandedViveTracker : ViveTracker
172172
{
173173
[InputControl]
@@ -196,7 +196,7 @@ protected override void FinishSetup()
196196
/// <summary>
197197
/// An Oculus Touch controller.
198198
/// </summary>
199-
[InputControlLayout(displayName = "Oculus Touch Controller (OpenVR)", commonUsages = new[] { "LeftHand", "RightHand" })]
199+
[InputControlLayout(displayName = "Oculus Touch Controller (OpenVR)", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
200200
public class OpenVROculusTouchController : XRControllerWithRumble
201201
{
202202
[InputControl]

Packages/com.unity.inputsystem/InputSystem/Plugins/XR/Devices/WindowsMR.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ namespace UnityEngine.XR.WindowsMR.Input
1010
/// <summary>
1111
/// A Windows Mixed Reality XR headset.
1212
/// </summary>
13-
[InputControlLayout(displayName = "Windows MR Headset")]
13+
[InputControlLayout(displayName = "Windows MR Headset", hideInUI = true)]
1414
public class WMRHMD : XRHMD
1515
{
1616
[InputControl]
@@ -29,7 +29,7 @@ protected override void FinishSetup()
2929
/// <summary>
3030
/// A Windows Mixed Reality XR controller.
3131
/// </summary>
32-
[InputControlLayout(displayName = "HoloLens Hand", commonUsages = new[] { "LeftHand", "RightHand" })]
32+
[InputControlLayout(displayName = "HoloLens Hand", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
3333
public class HololensHand : XRController
3434
{
3535
[InputControl(noisy = true, aliases = new[] { "gripVelocity" })]
@@ -52,7 +52,7 @@ protected override void FinishSetup()
5252
}
5353
}
5454

55-
[InputControlLayout(displayName = "Windows MR Controller", commonUsages = new[] { "LeftHand", "RightHand" })]
55+
[InputControlLayout(displayName = "Windows MR Controller", commonUsages = new[] { "LeftHand", "RightHand" }, hideInUI = true)]
5656
public class WMRSpatialController : XRControllerWithRumble
5757
{
5858
[InputControl(aliases = new[] { "Primary2DAxis", "thumbstickaxes" })]

0 commit comments

Comments
 (0)