Selectable 位于当前对象右侧的 Selectable 对象。
查找此对象右侧的可选择对象。
using UnityEngine; using System.Collections; using UnityEngine.UI; // required when using UI elements in scripts
public class ExampleClass : MonoBehaviour { public Button btnMain;
public void Start() { //Finds and assigns the selectable to the Right of the main button. Selectable newSelectable = btnMain.FindSelectableOnRight();
Debug.Log(newSelectable.name); } }