ResetAndClose() 개인적인 메소드

private ResetAndClose ( ) : void
리턴 void
예제 #1
0
        internal static void OnSubmitted(Task task)
        {
            WindowChange[] array = Resources.FindObjectsOfTypeAll(typeof(WindowChange)) as WindowChange[];
            if (array.Length == 0)
            {
                return;
            }
            WindowChange windowChange = array[0];

            windowChange.assetList          = task.assetList;
            windowChange.submitResultCode   = task.resultCode;
            windowChange.submitErrorMessage = null;
            if ((task.resultCode & 2) != 0)
            {
                string    empty    = string.Empty;
                Message[] messages = task.messages;
                for (int i = 0; i < messages.Length; i++)
                {
                    Message message = messages[i];
                    if (message.severity == Message.Severity.Error)
                    {
                        WindowChange expr_77 = windowChange;
                        expr_77.submitErrorMessage = expr_77.submitErrorMessage + empty + message.message;
                    }
                }
            }
            if ((task.resultCode & 3) != 0)
            {
                WindowPending.UpdateAllWindows();
                bool flag = windowChange.changeSet == null;
                if (flag)
                {
                    Task task2 = Provider.Status(string.Empty);
                    task2.Wait();
                    WindowPending.ExpandLatestChangeSet();
                }
            }
            if ((task.resultCode & 1) != 0)
            {
                windowChange.ResetAndClose();
            }
            else
            {
                windowChange.RefreshList();
            }
        }
예제 #2
0
        internal static void OnSubmitted(Task task)
        {
            WindowChange[] objectsOfTypeAll = Resources.FindObjectsOfTypeAll(typeof(WindowChange)) as WindowChange[];
            if (objectsOfTypeAll.Length == 0)
            {
                return;
            }
            WindowChange windowChange1 = objectsOfTypeAll[0];

            windowChange1.assetList          = task.assetList;
            windowChange1.submitResultCode   = task.resultCode;
            windowChange1.submitErrorMessage = (string)null;
            if ((task.resultCode & 2) != 0)
            {
                string empty = string.Empty;
                foreach (Message message in task.messages)
                {
                    if (message.severity == Message.Severity.Error)
                    {
                        WindowChange windowChange2 = windowChange1;
                        string       str           = windowChange2.submitErrorMessage + empty + message.message;
                        windowChange2.submitErrorMessage = str;
                    }
                }
            }
            if ((task.resultCode & 3) != 0)
            {
                WindowPending.UpdateAllWindows();
                if (windowChange1.changeSet == null)
                {
                    Provider.Status(string.Empty).Wait();
                    WindowPending.ExpandLatestChangeSet();
                }
            }
            if ((task.resultCode & 1) != 0)
            {
                windowChange1.ResetAndClose();
            }
            else
            {
                windowChange1.RefreshList();
            }
        }
예제 #3
0
 internal static void OnSubmitted(Task task)
 {
     WindowChange[] changeArray = UnityEngine.Resources.FindObjectsOfTypeAll(typeof(WindowChange)) as WindowChange[];
     if (changeArray.Length != 0)
     {
         WindowChange change = changeArray[0];
         change.assetList          = task.assetList;
         change.submitResultCode   = task.resultCode;
         change.submitErrorMessage = null;
         if ((task.resultCode & 2) != 0)
         {
             string str = "";
             foreach (Message message in task.messages)
             {
                 if (message.severity == Message.Severity.Error)
                 {
                     change.submitErrorMessage = change.submitErrorMessage + str + message.message;
                 }
             }
         }
         if ((task.resultCode & 3) != 0)
         {
             WindowPending.UpdateAllWindows();
             if (change.changeSet == null)
             {
                 Provider.Status("").Wait();
                 WindowPending.ExpandLatestChangeSet();
             }
         }
         if ((task.resultCode & 1) != 0)
         {
             change.ResetAndClose();
         }
         else
         {
             change.RefreshList();
         }
     }
 }