Skip to content

Commit 4664c7c

Browse files
authored
Don't ask for the Android XR hand permission in-editor (#1059)
Update UnityHandsSubsystem.cs
1 parent 315837c commit 4664c7c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

org.mixedrealitytoolkit.input/Subsystems/Hands/UnityHandsSubsystem.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ private static void Register()
4848
/// </summary>
4949
public UnityHandsSubsystem()
5050
{
51-
#if UNITY_ANDROID
51+
#if UNITY_ANDROID && !UNITY_EDITOR
5252
if (!Permission.HasUserAuthorizedPermission(HandTrackingPermission))
5353
{
5454
PermissionCallbacks callbacks = new();
@@ -84,7 +84,7 @@ void OnPermissionGranted(string permission)
8484
{
8585
Debug.Log($"{HandTrackingPermission} newly granted for MRTK.");
8686
}
87-
#endif // UNITY_ANDROID
87+
#endif // UNITY_ANDROID && !UNITY_EDITOR
8888
}
8989

9090
private class UnityHandContainer : HandDataContainer

0 commit comments

Comments
 (0)