/// <summary> /// Auto-focuses the continue button. Useful for gamepads. /// </summary> public void AutoFocus(bool allowStealFocus = true) { if (continueButton != null && allowStealFocus) { continueButton.Select(); continueButton.OnSelect(null); } }
private void SelectButton(UnityEngine.UI.Button button) { if (button == null) { return; } button.Select(); button.OnSelect(null); }
// Code that runs every frame. public override void OnEnter() { button = (UnityEngine.UI.Button)gameButtonGui.Value; button.OnSelect(null); }