Expose UI_MODE_TYPE_VR_HEADSET in PlatformConstants

Summary:
The Android version of PlatformConstants exposes the device's [UI Mode]( https://developer.android.com/guide/topics/resources/providing-resources#UiModeQualifier). It is missing the case for 'vrheadset', added in Android API 26. We should return the expected result when this is queried.

Changelog:
[Android][Added] - Expose UI_MODE_TYPE_VR_HEADSET in PlatformConstants

Reviewed By: rshest

Differential Revision: D38495875

fbshipit-source-id: fd904bd11213448415b7d75145d9ba6311ed407b
This commit is contained in:
Nick Gerleman
2022-08-08 23:41:07 -07:00
committed by Facebook GitHub Bot
parent 584b968683
commit 77c256ca91
@@ -50,6 +50,8 @@ public class AndroidInfoModule extends NativePlatformConstantsAndroidSpec implem
return "desk";
case Configuration.UI_MODE_TYPE_WATCH:
return "watch";
case Configuration.UI_MODE_TYPE_VR_HEADSET:
return "vrheadset";
case Configuration.UI_MODE_TYPE_NORMAL:
return "normal";
default: