コード例 #1
0
        public void numbersChecked(Object sender, CheckNumbersCompletedEventArgs e)
        {
            if (e.Result.ValidNumbers != null)
            {
                InvokeOnMainThread(delegate() {
                    //address book stuff
                    ABAddressBook addressBook = new ABAddressBook();
                    ABPerson[] allContacts    = addressBook.GetPeople();

                    _contacts.Clear();                     //remove old

                    foreach (var contact in allContacts)
                    {
                        var phone = contact.GetPhones();
                        foreach (var number in phone)
                        {
                            if (e.Result.ValidNumbers.Contains(number.Value.Replace(" ", string.Empty).ToString()))
                            {
                                _contacts.Add(contact);
                            }
                        }
                    }
                    //-----------------------------------------------

                    //TableView.DataSource = new ContactsTableDataSource (this, _contacts);
                    //TableView.Delegate = new ContactsTableViewDelegate (this, _contacts);

                    _loading.StopAnimating();                     //stop animating
                    _loading.RemoveFromSuperview();
                    _tableView.ReloadData();
                });
            }
        }
コード例 #2
0
        public void meetingRequested(Object sender, CreateMeetingCompletedEventArgs e)
        {
            try
            {
                ServiceHelper.instance.currentMeeting = e.Result.CreatedMeeting;

                //stop animating
                _loading.StopAnimating();
                _loading.RemoveFromSuperview();

                InvokeOnMainThread(delegate() { _controller.NavigationController.PushViewController(new MapViewController(), true); });
            }
            catch
            {
                MessageHelper.showErrorMesage("getMeetingRequest failed");;
            }
        }
コード例 #3
0
 public override void ViewWillDisappear(bool animated)
 {
     base.ViewDidDisappear(animated);
     _loading.StopAnimating();
     _loading.RemoveFromSuperview();             //remove loading
 }