Search Issue Tracker

Fix In Review for 2019.4.X

Votes

11

Found in

2017.4.0f1

2018.4.0f1

2019.1.0a1

2019.2.0a1

2019.2.0f1

2019.3.0a1

Issue ID

1174547

Regression

No

OnApplicationFocus() is not called when leaving or re-entering a VR application via the built-in "Home" or "Menu" buttons

Oculus

-

How to reproduce:
1. Open the user's project
2. Open the "SampleScene/Scenes" Scene
3. Enter the Play Mode
4. With HMD on press the Home button on your controller
5. Observe the Console

Expected result: OnApplicationFocus prints out false
Actual result: OnApplicationFocus is not called

Reproducible with: 2017.4.31f1, 2018.4.6f1, 2019.1.14f1, 2019.2.1f1, 2019.3.0a12

Comments (1)

  1. plmx

    Aug 08, 2019 17:21

    I submitted the original bug for this. The issue is this: There is currently no way at all using plain Unity to determine if the VR app loses focus in VR (i.e. if the user goes to visit the VR 'home' or 'store' by pressing the 'system' button) . This is bad because the game should be able to react to this event by going into pause mode.

    This applies to Rift, Vive, and Windows Mixed Reality headsets at least.

    It should be pointed out that OpenVR does contain an "InputFocus" event which works for the Vive, the WMR headsets, and for the 'menu' button on the Rift (which leads to SteamVR), but not for the 'Oculus' button on the Rift (which leads to the Oculus menu).

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.