public void Track(string e, ChadderError error)
 {
     try
     {
         Track(string.Format("{0} - {1}", e, error.ToString()));
     }
     catch { }
 }
 public bool ShowErrorIfNotOk(ChadderError result)
 {
     if (result == ChadderError.OK)
     {
         return(true);
     }
     ChadderApp.UIHelper.ShowError(result);
     return(false);
 }
예제 #3
0
 public static string GetString(ChadderError error)
 {
     try
     {
         return(error.ToString().t());
     }
     catch
     {
         return(error.ToString());
     }
 }
예제 #4
0
        public async void ToggleBlock(ChadderContact contact)
        {
            ChadderApp.UIHelper.ShowLoading();
            ChadderError result = ChadderError.OK;

            if (contact.Type == Data.RelationshipType.FRIENDS)
            {
                result = await Source.SetFriendType(contact, Data.RelationshipType.BLOCKED);
            }
            else
            {
                result = await Source.SetFriendType(contact, Data.RelationshipType.FRIENDS);
            }
            ChadderApp.UIHelper.HideLoading();
            ShowErrorIfNotOk(result);
        }
예제 #5
0
 public void ShowError(ChadderError error)
 {
     ShowError(GetString(error));
 }
예제 #6
0
 public void Ok(ChadderError e)
 {
     Assert.AreEqual(ChadderError.OK, e);
 }
예제 #7
0
 public BasicArrayResponse(ChadderError error)
 {
     Error = error;
     List  = new List <T>();
 }
예제 #8
0
 public BasicResponse(ChadderError e)
 {
     Time  = DateTime.UtcNow;
     Error = e;
 }
예제 #9
0
 static public void Track(string e, ChadderError error)
 {
     Track(string.Format("{0} - {1}", e, error));
 }
예제 #10
0
 public void Track(string e, ChadderError error)
 {
 }