public void OnSelect() { Debug.Log("keyboardSet"); KeyboardMain km = Resources.FindObjectsOfTypeAll <KeyboardMain>()[0]; //km.gameObject.SetActive(true); km.InputDisplay = transform.parent.Find("Text").gameObject; km.OnStart(transform.parent); //keyboard = new TouchScreenKeyboard("Sample text that goes into the textbox", TouchScreenKeyboardType.Default, false, false, false, false, "sample prompting text that goes above the textbox"); }
// Use this for initialization void Start() { if (KeyboardOne == null) { KeyboardOne = FindObjectOfType <KeyboardMain>().gameObject; } keyboardMain = KeyboardOne.GetComponent <KeyboardMain>(); audioSource = KeyboardOne.GetComponent <AudioSource>(); keyColor = GetComponent <MeshRenderer>().material.GetColor("_Color"); if (GetComponent <Microsoft.MixedReality.Toolkit.UI.PressableButton>() != null && GetComponent <Microsoft.MixedReality.Toolkit.UI.PressableButton>().enabled) { GetComponent <Microsoft.MixedReality.Toolkit.UI.PressableButton>().ButtonPressed.AddListener(UI_OnClick); } if (GetComponentInChildren <Microsoft.MixedReality.Toolkit.UI.Interactable>() != null) { GetComponentInChildren <Microsoft.MixedReality.Toolkit.UI.Interactable>().OnClick.AddListener(UI_OnClick); } }
// Use this for initialization void Start() { keyboardMain = KeyboardOne.GetComponent <KeyboardMain>(); audioSource = KeyboardOne.GetComponent <AudioSource>(); keyColor = GetComponent <MeshRenderer>().material.GetColor("_Color"); }
// Use this for initialization void Start() { keyboardMain = KeyboardOne.GetComponent <KeyboardMain>(); audioSource = KeyboardOne.GetComponent <AudioSource>(); }