private new static void Show()
 {
     window = CreateInstance <NotificationsPopup>();
     window.titleContent = new GUIContent("Notifications");
     window.minSize      = Vector2.zero;
     window.ShowPopup();
 }
Esempio n. 2
0
        /// <summary> Create clip data and send the request. </summary>
        private void Generate()
        {
            string path = EditorUtility.SaveFilePanel("Save OneShot clip", savePath, "", "wav");

            if (string.IsNullOrEmpty(path))
            {
                return;
            }
            savePath = Path.GetDirectoryName(path);
            AsyncRequest.Make(text.BuildResembleString(), voiceUUID, path);
            string name = Path.GetFileName(path);

            name = name.Remove(name.Length - 4);
            NotificationsPopup.Add("OneShot request send : " + name, MessageType.Info, null);
            text.SelectAll();
            text.Delete();
        }