示例#1
0
 private void doCall(WebServiceParameters call, Action callback)
 {
     call.getParameters.Add("token", _token);
     new EditorWWWWaitUntil(call, (WebServiceReturnStatus status) =>
     {
         if (status.httpErrorCode > 0 && status.httpErrorCode != 200)
         {
             EditorUtility.DisplayDialog("ERROR", "Error while ordering translation. Please try again.", "OK");
         }
         if (callback != null)
         {
             callback();
         }
     }
                            );
 }
示例#2
0
        private WebServiceReturnStatus doCall(WebServiceParameters call)
        {
            IWebService req = new SyncronousEditorWebRequest();

            try
            {
                call.getParameters.Add("token", _token);

                WebServiceReturnStatus result = req.request(call);
                return(result);
            }
            catch (HttpErrorCode code)
            {
                Debug.Log(code.code + " http error");
                throw;
            }
        }