void ReleaseDesignerOutlets()
        {
            if (Cell1 != null)
            {
                Cell1.Dispose();
                Cell1 = null;
            }

            if (Cell2 != null)
            {
                Cell2.Dispose();
                Cell2 = null;
            }

            if (Cell3 != null)
            {
                Cell3.Dispose();
                Cell3 = null;
            }

            if (inboxCell != null)
            {
                inboxCell.Dispose();
                inboxCell = null;
            }
        }
Exemplo n.º 2
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            cell.Accessory = UITableViewCellAccessory.DisclosureIndicator;
            return(cell);
        }
Exemplo n.º 3
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            cell.SelectionStyle = UITableViewCellSelectionStyle.None;
            return(cell);
        }
Exemplo n.º 4
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            //Habilitar para deixar transparente com Esse Renderer
            // cell.SelectionStyle = UITableViewCellSelectionStyle.None;

            switch (item.StyleId)
            {
            case "none":
                cell.Accessory = UIKit.UITableViewCellAccessory.None;
                break;

            case "checkmark":
                cell.Accessory = UIKit.UITableViewCellAccessory.Checkmark;
                break;

            case "detail-button":
                cell.Accessory = UIKit.UITableViewCellAccessory.DetailButton;
                break;

            case "detail-disclosure-button":
                cell.Accessory = UIKit.UITableViewCellAccessory.DetailDisclosureButton;
                break;

            case "disclosure":
            default:
                cell.Accessory = UIKit.UITableViewCellAccessory.DisclosureIndicator;
                break;
            }
            return(cell);
        }
Exemplo n.º 5
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            if (cell != null)
            {
                cell.BackgroundColor = UIColor.Clear;

                switch (item.StyleId)
                {
                case "checkmark":
                    cell.Accessory = UIKit.UITableViewCellAccessory.Checkmark;
                    break;

                case "detail-button":
                    cell.Accessory = UIKit.UITableViewCellAccessory.DetailButton;
                    break;

                case "detail-disclosure-button":
                    cell.Accessory = UIKit.UITableViewCellAccessory.DetailDisclosureButton;
                    break;

                case "disclosure":
                    cell.Accessory = UIKit.UITableViewCellAccessory.DisclosureIndicator;
                    break;

                case "none":
                default:
                    cell.Accessory = UIKit.UITableViewCellAccessory.None;
                    break;
                }
            }

            return(cell);
        }
Exemplo n.º 6
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell,
                                                      UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            cell.BackgroundColor = UIColor.Red;
            return(cell);
        }
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            //cell.sw
            cell.SelectionStyle = UITableViewCellSelectionStyle.Gray;
            return(cell);
        }
Exemplo n.º 8
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tableView)
        {
            var thecell = (CustomListViewCell)item;
            var cell    = (BubbleCell)tableView.DequeueReusableCell(Id) ?? new BubbleCell(thecell.IsMe);

            cell.Update(thecell.Text);
            return(cell);
        }
 private void ReleaseDesignerOutlets()
 {
     if (signOutCell != null)
     {
         signOutCell.Dispose();
         signOutCell = null;
     }
 }
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            tv.AllowsSelection = false;
            var cell = base.GetCell(item, reusableCell, tv);

            cell.SelectionStyle = UITableViewCellSelectionStyle.None;

            return(cell);
        }
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            if (cell != null)
            {
                cell.SelectionStyle = UITableViewCellSelectionStyle.None;
            }

            return(cell);
        }
Exemplo n.º 12
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var navCell = (NavigationCell)item;
            var cell    = base.GetCell(item, reusableCell, tv);

            if (cell != null && navCell.UseIOSAccessory)
            {
                cell.Accessory = UITableViewCellAccessory.DisclosureIndicator;
            }
            return(cell);
        }
Exemplo n.º 13
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            cell.SelectedBackgroundView = new UIView()
            {
                BackgroundColor = UIColor.Clear
            };

            return(cell);
        }
        public override UITableViewCell GetCell(UITableView tableView, NSIndexPath indexPath)
        {
            Sample s = list[indexPath.Row];

            UIKit.UITableViewCell cell = this.TableView.DequeueReusableCell("Cell");
            cell.TextLabel.Text       = s.Title;
            cell.TextLabel.TextColor  = new UIColor((nfloat)176.0f / 256.0f, (nfloat)15.0f / 256.0f, (nfloat)80.0f / 256.0f, (nfloat)1.0f);
            cell.DetailTextLabel.Text = s.Description;
            cell.ImageView.Image      = new UIImage(s.Image);
            return(cell);
        }
Exemplo n.º 15
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            Contract.Ensures(Contract.Result <UITableViewCell>() != null);
            var cell = base.GetCell(item, reusableCell, tv);

            cell.SelectedBackgroundView = new UIView
            {
                BackgroundColor = UIColor.FromRGB(233, 217, 133)
            };

            return(cell);
        }
 public override UITableViewCell GetCell(UITableView tableView, NSIndexPath indexPath)
 {
     Sample s = list[indexPath.Row];
     UIKit.UITableViewCell cell = this.TableView.DequeueReusableCell("Cell");
     var localizedString1 = NSBundle.MainBundle.LocalizedString(s.Title, "optional");
     cell.TextLabel.Text = localizedString1;
     cell.TextLabel.TextColor = UIColor.DarkGray;
     var localizedString = NSBundle.MainBundle.LocalizedString(s.Description, "optional");
     cell.DetailTextLabel.Text = localizedString;
     cell.DetailTextLabel.TextColor = UIColor.DarkGray;
     cell.ImageView.Image = new UIImage(s.Image);
     return cell;
 }
Exemplo n.º 17
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell    = base.GetCell(item, reusableCell, tv);
            var element = (CustomViewCell)item;

            switch (element.Accessory)
            {
            case Accessory.DisclosureIndicator:
                cell.Accessory = UITableViewCellAccessory.DisclosureIndicator;
                break;
            }
            return(cell);
        }
Exemplo n.º 18
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            cell.Accessory = UIKit.UITableViewCellAccessory.DisclosureIndicator;

            //set blue border for image
            cell.ImageView.Layer.BorderColor = Color.White.ToCGColor();
            cell.ImageView.Layer.BorderWidth = 1;
            cell.BackgroundColor             = Color.FromHex(ColorStyles.XamarinDark).ToUIColor();

            return(cell);
        }
        void ReleaseDesignerOutlets()
        {
            if (AccessKeyID != null)
            {
                AccessKeyID.Dispose();
                AccessKeyID = null;
            }

            if (AccessKeySecret != null)
            {
                AccessKeySecret.Dispose();
                AccessKeySecret = null;
            }

            if (BucketName != null)
            {
                BucketName.Dispose();
                BucketName = null;
            }

            if (Endpoint != null)
            {
                Endpoint.Dispose();
                Endpoint = null;
            }

            if (SaveButton != null)
            {
                SaveButton.Dispose();
                SaveButton = null;
            }

            if (ServiceName != null)
            {
                ServiceName.Dispose();
                ServiceName = null;
            }

            if (ShareCredentialsCell != null)
            {
                ShareCredentialsCell.Dispose();
                ShareCredentialsCell = null;
            }

            if (StoreCredentialsCell != null)
            {
                StoreCredentialsCell.Dispose();
                StoreCredentialsCell = null;
            }
        }
        void ReleaseDesignerOutlets()
        {
            if (crossDissolveCell != null)
            {
                crossDissolveCell.Dispose();
                crossDissolveCell = null;
            }

            if (diagonalWipeCell != null)
            {
                diagonalWipeCell.Dispose();
                diagonalWipeCell = null;
            }
        }
Exemplo n.º 21
0
        void ReleaseDesignerOutlets()
        {
            if (AccountKey != null)
            {
                AccountKey.Dispose();
                AccountKey = null;
            }

            if (AccountName != null)
            {
                AccountName.Dispose();
                AccountName = null;
            }

            if (Container != null)
            {
                Container.Dispose();
                Container = null;
            }

            if (EndpointSuffix != null)
            {
                EndpointSuffix.Dispose();
                EndpointSuffix = null;
            }

            if (SaveButton != null)
            {
                SaveButton.Dispose();
                SaveButton = null;
            }

            if (ServiceName != null)
            {
                ServiceName.Dispose();
                ServiceName = null;
            }

            if (ShareCredentialsCell != null)
            {
                ShareCredentialsCell.Dispose();
                ShareCredentialsCell = null;
            }

            if (StoreCredentialsCell != null)
            {
                StoreCredentialsCell.Dispose();
                StoreCredentialsCell = null;
            }
        }
        void ReleaseDesignerOutlets ()
        {
            if (ModeAstroTableViewCell != null) {
                ModeAstroTableViewCell.Dispose ();
                ModeAstroTableViewCell = null;
            }

            if (ModePanoramaTableViewCell != null) {
                ModePanoramaTableViewCell.Dispose ();
                ModePanoramaTableViewCell = null;
            }

            if (ModeSmsTableViewCell != null) {
                ModeSmsTableViewCell.Dispose ();
                ModeSmsTableViewCell = null;
            }
        }
        public override UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            switch (item.StyleId)
            {
            case "checkmark":
                if (cell.Accessory != UITableViewCellAccessory.Checkmark)
                {
                    cell.Accessory = UITableViewCellAccessory.Checkmark;
                }
                break;

            case "detail-button":
                if (cell.Accessory != UITableViewCellAccessory.DetailButton)
                {
                    cell.Accessory = UITableViewCellAccessory.DetailButton;
                }
                break;

            case "detail-disclosure-button":
                if (cell.Accessory != UITableViewCellAccessory.DetailDisclosureButton)
                {
                    cell.Accessory = UITableViewCellAccessory.DetailDisclosureButton;
                }
                break;

            case "disclosure":
                if (cell.Accessory != UITableViewCellAccessory.DisclosureIndicator)
                {
                    cell.Accessory = UITableViewCellAccessory.DisclosureIndicator;
                }
                break;

            case "none":
            default:
                if (cell.Accessory != UITableViewCellAccessory.None)
                {
                    cell.Accessory = UITableViewCellAccessory.None;
                }
                break;
            }

            return(cell);
        }
        void ReleaseDesignerOutlets()
        {
            if (btnCancel != null)
            {
                btnCancel.Dispose();
                btnCancel = null;
            }

            if (cellSizeTableViewCell != null)
            {
                cellSizeTableViewCell.Dispose();
                cellSizeTableViewCell = null;
            }

            if (debuggingEnabledTableViewCell != null)
            {
                debuggingEnabledTableViewCell.Dispose();
                debuggingEnabledTableViewCell = null;
            }

            if (groupingEnabledTableViewCell != null)
            {
                groupingEnabledTableViewCell.Dispose();
                groupingEnabledTableViewCell = null;
            }

            if (marginFactorTableViewCell != null)
            {
                marginFactorTableViewCell.Dispose();
                marginFactorTableViewCell = null;
            }

            if (maxZoomLevelTableViewCell != null)
            {
                maxZoomLevelTableViewCell.Dispose();
                maxZoomLevelTableViewCell = null;
            }

            if (minUniqueLocationsTableViewCell != null)
            {
                minUniqueLocationsTableViewCell.Dispose();
                minUniqueLocationsTableViewCell = null;
            }
        }
Exemplo n.º 25
0
        void ReleaseDesignerOutlets()
        {
            if (dailyWaterInTakeCell != null)
            {
                dailyWaterInTakeCell.Dispose();
                dailyWaterInTakeCell = null;
            }

            if (settingsView != null)
            {
                settingsView.Dispose();
                settingsView = null;
            }

            if (waterCalculatorCell != null)
            {
                waterCalculatorCell.Dispose();
                waterCalculatorCell = null;
            }
        }
Exemplo n.º 26
0
        void ReleaseDesignerOutlets()
        {
            if (forceIPv4Cell != null)
            {
                forceIPv4Cell.Dispose();
                forceIPv4Cell = null;
            }

            if (forceIPv6Cell != null)
            {
                forceIPv6Cell.Dispose();
                forceIPv6Cell = null;
            }

            if (startStopCell != null)
            {
                startStopCell.Dispose();
                startStopCell = null;
            }
        }
        void ReleaseDesignerOutlets()
        {
            if (dateLabel != null)
            {
                dateLabel.Dispose();
                dateLabel = null;
            }

            if (datePicker != null)
            {
                datePicker.Dispose();
                datePicker = null;
            }

            if (datePickerViewCell != null)
            {
                datePickerViewCell.Dispose();
                datePickerViewCell = null;
            }
        }
Exemplo n.º 28
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var         tvc         = reusableCell as CellTableViewCell;
            BEMCheckBox bemCheckBox = null;

            if (tvc == null)
            {
                tvc = new CellTableViewCell(UIKit.UITableViewCellStyle.Value1, CellName);
            }
            else
            {
                bemCheckBox = tvc.AccessoryView as BEMCheckBox;
                tvc.Cell.PropertyChanged -= OnCellPropertyChanged;
            }

            SetRealCell(item, tvc);

            if (bemCheckBox == null)
            {
                bemCheckBox = new BEMCheckBox(Constants.CheckBoxSize);
                bemCheckBox.ValueChanged += OnCheckBoxValueChanged;
                tvc.AccessoryView         = bemCheckBox;
            }

            var boolCell = (CheckBoxCell)item;

            tvc.Cell = item;
            tvc.Cell.PropertyChanged += OnCellPropertyChanged;
            tvc.AccessoryView         = bemCheckBox;
            tvc.TextLabel.Text        = boolCell.Text;

            bemCheckBox.On = boolCell.On;

            WireUpForceUpdateSizeRequested(item, tvc, tv);

            UpdateBackground(tvc, item);
            UpdateIsEnabled(tvc, boolCell);

            return(tvc);
        }
Exemplo n.º 29
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            if (item.Parent is WTableView)
            {
                if (!(item.Parent as WTableView).SelectionEnabled)
                {
                    cell.SelectionStyle = UIKit.UITableViewCellSelectionStyle.None;
                }
                else
                {
                    cell.SelectionStyle = UIKit.UITableViewCellSelectionStyle.Default;
                }
            }
            else if (item.Parent is WListView)
            {
                var listview = item.Parent as WListView;

                if (!(listview.Parent as WListView).SelectionEnabled)
                {
                    cell.SelectionStyle = UIKit.UITableViewCellSelectionStyle.None;
                }
                else
                {
                    cell.SelectionStyle = UIKit.UITableViewCellSelectionStyle.Default;
                }


                if (listview.SelectionColor != Color.Default)
                {
                    var bgView = new UIView();
                    bgView.BackgroundColor      = listview.SelectionColor.ToUIColor();
                    cell.SelectedBackgroundView = bgView;
                }
            }

            return(cell);
        }
Exemplo n.º 30
0
        public override UIKit.UITableViewCell GetCell(Xamarin.Forms.Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var x = (NativeCell)item;

            Console.WriteLine(x);

            NativeiOSCell c = reusableCell as NativeiOSCell;

            if (c == null)
            {
                c = new NativeiOSCell(rid);
            }

            UIImage i = null;

            if (!String.IsNullOrWhiteSpace(x.ImageFilename))
            {
                i = UIImage.FromFile("Images/" + x.ImageFilename + ".jpg");
            }
            c.UpdateCell(x.Name, x.Category, i);

            return(c);
        }
Exemplo n.º 31
0
        public override UIKit.UITableViewCell GetCell(Cell item, UIKit.UITableViewCell reusableCell, UIKit.UITableView tv)
        {
            var cell = base.GetCell(item, reusableCell, tv);

            switch (item.StyleId)
            {
            case "none":
                cell.Accessory = UIKit.UITableViewCellAccessory.None;
                break;

            case "checkmark":
                cell.Accessory = UIKit.UITableViewCellAccessory.Checkmark;
                break;

            case "detail-button":
                cell.Accessory = UIKit.UITableViewCellAccessory.DetailButton;
                break;

            case "detail-disclosure-button":
                cell.Accessory      = UIKit.UITableViewCellAccessory.DetailDisclosureButton;
                cell.SelectionStyle = UITableViewCellSelectionStyle.None;
                break;

            case "disclosure":
            default:
                cell.Accessory      = UIKit.UITableViewCellAccessory.DisclosureIndicator;
                cell.SelectionStyle = UITableViewCellSelectionStyle.None;
                break;
            }

            CGRect rect = new CGRect(0, 0, 1, 1);
            CGSize size = rect.Size;

            UIGraphics.BeginImageContext(size);
            CGContext currentContext = UIGraphics.GetCurrentContext();

            currentContext.SetFillColor(Color.Green.ToCGColor());
            currentContext.FillRect(rect);
            var backgroundImage = UIGraphics.GetImageFromCurrentImageContext();

            currentContext.Dispose();
            CGContext currentNormalContext = UIGraphics.GetCurrentContext();

            currentNormalContext.SetFillColor(Color.FromHex("AC4E4C").ToCGColor());
            currentNormalContext.FillRect(rect);
            var normalBackgroundImage = UIGraphics.GetImageFromCurrentImageContext();

            currentNormalContext.Dispose();

            var globalContextViewCell = Type.GetType("Xamarin.Forms.Platform.iOS.ContextActionsCell, Xamarin.Forms.Platform.iOS, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null");

            // Now change the static field value! "NormalBackground" OR "DestructiveBackground"
            if (globalContextViewCell != null)
            {
                var normalButton = globalContextViewCell.GetField("NormalBackground", BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Static);

                if (normalButton != null)
                {
                    normalButton.SetValue(null, backgroundImage);
                }

                var destructiveButton = globalContextViewCell.GetField("DestructiveBackground", BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Static);

                if (destructiveButton != null)
                {
                    destructiveButton.SetValue(null, normalBackgroundImage);
                }
            }

            return(cell);
        }