/// <summary> /// Return this instance to cache. /// </summary> protected virtual void Return() { Templates.ToCache(this); Buttons.Disable(); ResetParametres(); }
/// <summary> /// Close modal helper with the specified index. /// </summary> /// <param name="index">Index.</param> public static void Close(int index) { if ((used != null) && (used.ContainsKey(index))) { used[index].OnClick.RemoveAllListeners(); Templates.ToCache(used[index]); used.Remove(index); } }
/// <summary> /// Return this instance to cache. /// </summary> public void Return() { Templates.ToCache(this); ShowAnimation = oldShowAnimation; HideAnimation = oldHideAnimation; SetMessage(Templates.Get(TemplateName).text.text); }
/// <summary> /// Return this instance to cache. /// </summary> public void Return() { Templates.ToCache(this); ShowAnimation = oldShowAnimation; HideAnimation = oldHideAnimation; if (text != null) { text.text = Templates.Get(TemplateName).text.text; } }
/// <summary> /// Return this instance to cache. /// </summary> public void Return() { Templates.ToCache(this); ShowAnimation = oldShowAnimation; HideAnimation = oldHideAnimation; var rt = transform as RectTransform; rt.SetSizeWithCurrentAnchors(RectTransform.Axis.Horizontal, oldSize.x); rt.SetSizeWithCurrentAnchors(RectTransform.Axis.Vertical, oldSize.y); rt.localRotation = oldRotation; var le = GetComponent <LayoutElement>(); if (le != null) { le.ignoreLayout = false; } SetMessage(Templates.Get(TemplateName).text.text); }
/// <summary> /// Close modal helper with the specified index. /// </summary> /// <param name="index">Index.</param> public static void Close(int index) { Templates.ToCache(used[index]); used.Remove(index); }