Esempio n. 1
0
            public override void CommitEditingStyle(UITableView aTableView, UITableViewCellEditingStyle aEditingStyle, NSIndexPath aIndexPath)
            {
                if (aEditingStyle == UITableViewCellEditingStyle.Delete)
                {
                    iList.RemoveAt(aIndexPath.Row);

                    aTableView.DeleteRows(new NSIndexPath[] { aIndexPath }, UITableViewRowAnimation.Right);

                    iOption.Set(StringListConverter.ListToString(iList));
                }
            }
Esempio n. 2
0
        private void ButtonRemoveClick(object sender, EventArgs e)
        {
            // just remove the values from the option list and let the eventing
            // update the view

            int offset = 0;

            foreach (int index in iListFolders.SelectedIndices)
            {
                iList.RemoveAt(index + offset--);
            }

            iOption.Set(StringListConverter.ListToString(iList));
        }
Esempio n. 3
0
        private void ActionEventRemove(Id aSender)
        {
            NSIndexSet rows = iTableView.SelectedRowIndexes;

            uint index = rows.LastIndex;

            while (index != FoundationFramework.NSNotFound)
            {
                if (index < iList.Count)
                {
                    iList.RemoveAt((int)index);
                    iOption.Set(StringListConverter.ListToString(iList));
                }
                index = rows.IndexLessThanIndex(index);
            }
        }
Esempio n. 4
0
                private bool Update(UITextField aTextField)
                {
                    if (iIndex < iList.Count)
                    {
                        if (string.IsNullOrEmpty(aTextField.Text))
                        {
                            iList.RemoveAt(iIndex);
                        }
                        else
                        {
                            if (Uri.IsWellFormedUriString(aTextField.Text, UriKind.Absolute))
                            {
                                iList[iIndex] = aTextField.Text;
                            }
                            else
                            {
                                return(false);
                            }
                        }
                    }
                    else
                    {
                        if (!string.IsNullOrEmpty(aTextField.Text))
                        {
                            if (Uri.IsWellFormedUriString(aTextField.Text, UriKind.Absolute))
                            {
                                iList.Add(aTextField.Text);
                            }
                            else
                            {
                                return(false);
                            }
                        }
                    }

                    iOption.Set(StringListConverter.ListToString(iList));

                    return(true);
                }
Esempio n. 5
0
 protected void Add(string aValue)
 {
     iList.Add(aValue);
     iOption.Set(StringListConverter.ListToString(iList));
 }