예제 #1
0
 // Token: 0x0600636E RID: 25454 RVA: 0x00235434 File Offset: 0x00233834
 public void SetupInputAndSubmitAndCancelButton(string placeholderText, InputField.InputType inputType, string submitText, Action <string, List <KeyCode>, Text> onSubmit, string cancelText, Action onCancel, bool hidePopupOnSubmit = true)
 {
     this.mOnSubmitDelegate = onSubmit;
     base.SetupRightButton(submitText, new Action(this.CloseAndSubmit));
     this.mOnCancelDelegate = onCancel;
     base.SetupLeftButton(cancelText, new Action(this.CloseAndCancel));
     this.mHidePopupOnSubmit = hidePopupOnSubmit;
 }
예제 #2
0
 // Token: 0x060063A1 RID: 25505 RVA: 0x002365C8 File Offset: 0x002349C8
 public void ShowDatePopupWithCancel(string title, string body, InputField.InputType inputType, string submitButtonText, Action <string, List <KeyCode>, Text> submitButtonAction, Action cancelButtonAction, string placeholderText = "Enter text....", bool hidePopupOnSubmit = true, Action <VRCUiPopup> additionalSetup = null)
 {
     if (cancelButtonAction == null)
     {
         cancelButtonAction = delegate
         {
             VRCUiManager.Instance.popups.HideCurrentPopup();
         };
     }
     this.DisableAllPopups();
     this.datePopup.gameObject.SetActive(true);
     this.datePopup.Initialize(title, body);
     this.datePopup.SetupInputAndSubmitAndCancelButton(placeholderText, inputType, submitButtonText, submitButtonAction, "Cancel", cancelButtonAction, hidePopupOnSubmit);
     if (additionalSetup != null)
     {
         additionalSetup(this.datePopup);
     }
     VRCUiManager.Instance.ShowScreen("UserInterface/MenuContent/Popups/DatePopup");
 }
예제 #3
0
 public static void ShowInputPopup(this VRCUiPopupManager vrcUiPopupManager, string title, string preFilledText, InputField.InputType inputType, bool keypad, string buttonText, Il2CppSystem.Action <string, List <KeyCode>, Text> buttonAction, Il2CppSystem.Action cancelAction, string boxText = "Enter text....", bool closeOnAccept = true, System.Action <VRCUiPopup> onCreated = null)
 {
     PopupManagerUtils.ShowUiInputPopup(title, preFilledText, inputType, keypad, buttonText, buttonAction, cancelAction, boxText, closeOnAccept, onCreated);
 }
예제 #4
0
 // Token: 0x0600636D RID: 25453 RVA: 0x0023540D File Offset: 0x0023380D
 public void SetupInputAndSubmitButton(string placeholderText, InputField.InputType inputType, string buttonText, Action <string, List <KeyCode>, Text> onSubmit, bool hidePopupOnSubmit = true)
 {
     this.mOnSubmitDelegate = onSubmit;
     base.SetupMiddleButton(buttonText, new Action(this.CloseAndSubmit));
     this.mHidePopupOnSubmit = hidePopupOnSubmit;
 }
        public static void ShowInputPopupWithCancel(this VRCUiPopupManager vrcUiPopupManager, string title, string content, InputField.InputType inputType, bool numeric,
                                                    string buttonText, Action <string, List <KeyCode>, Text> buttonAction, Action cancelAction, string placeholder = "Enter text....", bool hideOnSubmit = true, Action <VRCUiPopup> onCreated = null)
        {
            Action <string, Il2CppSystem.Collections.Generic.List <KeyCode>, Text> action = new Action <string, Il2CppSystem.Collections.Generic.List <KeyCode>, Text>((s, code, text) =>
            {
                List <KeyCode> keyCodes = new List <KeyCode>();
                for (int i = 0; i < code.Count; ++i)
                {
                    keyCodes.Add(code[i]);
                }
                buttonAction?.Invoke(s, keyCodes, text);
            });

            vrcUiPopupManager.Method_Public_Void_String_String_InputType_Boolean_String_Action_3_String_List_1_KeyCode_Text_Action_String_Boolean_Action_1_VRCUiPopup_1(
                title, content, inputType, numeric,
                buttonText, action,
                cancelAction ?? new Action(() => { }), placeholder, hideOnSubmit, onCreated ?? new Action <VRCUiPopup>(p => { }));
        }