public void clickCancle()
    {
        onCancleClickListener();
        DialogPanelScript self = GetComponent <DialogPanelScript> ();

        Destroy(self.title);
        Destroy(self.msg);
        Destroy(this);
        Destroy(gameObject);
    }
Exemple #2
0
    public void clickCancle()
    {
        SoundCtrl.getInstance().playSoundUI();
        onCancleClickListener();
        DialogPanelScript self = GetComponent <DialogPanelScript> ();

        Destroy(self.title);
        Destroy(self.msg);
        Destroy(this);
        Destroy(gameObject);
    }
    public override void OnInspectorGUI()
    {
        base.OnInspectorGUI();

        DialogPanelScript ds = (DialogPanelScript)target;

        if (GUILayout.Button("Show/Hide Dialog Panel"))
        {
            if ((bool)ds.IsHidden())
            {
                ds.StartCoroutine(ds.ShowDialogPanel());
            }
            else if (!(bool)ds.IsHidden())
            {
                ds.StartCoroutine(ds.HideDialogPanel());
            }
        }
    }