コード例 #1
0
    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");
    }
コード例 #2
0
ファイル: KeyboardGG.cs プロジェクト: skyzdev/D3DKeyboard
    // 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);
        }
    }
コード例 #3
0
 // Use this for initialization
 void Start()
 {
     keyboardMain = KeyboardOne.GetComponent <KeyboardMain>();
     audioSource  = KeyboardOne.GetComponent <AudioSource>();
     keyColor     = GetComponent <MeshRenderer>().material.GetColor("_Color");
 }
コード例 #4
0
 // Use this for initialization
 void Start()
 {
     keyboardMain = KeyboardOne.GetComponent <KeyboardMain>();
     audioSource  = KeyboardOne.GetComponent <AudioSource>();
 }