CustomEventSystem.cs 537 B

123456789101112131415
  1. using UnityEngine.EventSystems;
  2. //This script is used as a workaround to the unresponsive Unity UI in Safari and Brave caused by a Unity bug
  3. //If you already upgraded to Unity 2022, you may no longer need this
  4. //https://forum.unity.com/threads/ui-button-stops-working-permanently-after-switching-tabs-on-mobile-safari.1029688/
  5. namespace Imagine.WebAR.Samples
  6. {
  7. public class CustomEventSystem : EventSystem
  8. {
  9. protected override void OnApplicationFocus(bool hasFocus)
  10. {
  11. // Do Nothing
  12. }
  13. }
  14. }