void SetupView()
        {
            imgLogo.Image     = UIImage.FromBundle("logo").ImageWithRenderingMode(UIImageRenderingMode.AlwaysTemplate);
            imgLogo.TintColor = ColorHelper.FromType(ColorType.Logo);

            pagPager.PageIndicatorTintColor        = ColorHelper.FromType(ColorType.SecondaryRedBackground);
            pagPager.UserInteractionEnabled        = false;
            pagPager.CurrentPageIndicatorTintColor = ColorHelper.FromType(ColorType.RedBackground);
            labHeader.Text           = LangUtil.Get("Initial.Header");
            labHeader.TextColor      = ColorHelper.FromType(ColorType.RedBackground);
            labDescription.TextColor = ColorHelper.FromType(ColorType.Label);
            labDescription.Text      = string.Empty;
            //  viewAnimation.BackgroundColor = UIColor.FromRGBA(50, 0, 0, 40);

            if (UserUtil.Current.onboardingCompleted == false)
            {
                btnSkip.SetTitleColor(ColorHelper.FromType(ColorType.RedBackground), UIControlState.Normal);
                btnSkip.SetTitle(LangUtil.Get("Initial.Skip"), UIControlState.Normal);
                btnSkip.Hidden = false;

                pagPager.Pages = totalPages;

                btnNext.SetTitleColor(ColorHelper.FromType(ColorType.RedBackground), UIControlState.Normal);
                btnNext.SetTitle(LangUtil.Get("Initial.Next") + "", UIControlState.Normal);
            }
            else
            {
                btnSkip.Hidden  = true;
                pagPager.Hidden = true;
                btnNext.Hidden  = true;
            }

            ShowActivityIndicatorForNext(NextType.Next);
        }
        public override void ViewDidLoad()
        {
            base.ViewDidLoad();

            this.Title = LangUtil.Get("SettingsViewController.Coordinates.Format.Title");

            View.BackgroundColor = ColorHelper.FromType(ColorType.SystemGroupedBackground);

            table.BackgroundColor = UIColor.Clear;

            table.RowHeight          = UITableView.AutomaticDimension;
            table.EstimatedRowHeight = 70;
            var footer = new UIView(CGRect.FromLTRB(0, 0, View.Frame.Width, 1));

            footer.BackgroundColor = ColorHelper.FromType(ColorType.Separator);
            table.TableFooterView  = footer;

            labHeader.TextColor = ColorHelper.FromType(ColorType.Label);
            labHeader.Font      = FontConst.fontMediumRegular;
            labHeader.Text      = LangUtil.Get("SettingsViewController.Coordinates.Format.Header");

            settingsCoordinateFormatTableViewSource = new SettingsCoordinateFormatTableViewSource(this);
            table.Source = settingsCoordinateFormatTableViewSource;

            SetupData();
        }
        private void SetupNavigationBar()
        {
            Title = LangUtil.Get("Settings.heading");

            NavigationController.NavigationBar.Translucent         = false;
            NavigationController.NavigationBar.TitleTextAttributes = new UIStringAttributes()
            {
                ForegroundColor = ColorHelper.FromType(ColorType.NavigationbarLabel),
            };

            NavigationController.NavigationBar.TintColor = ColorHelper.FromType(ColorType.NavigationbarTint);
            View.BackgroundColor = ColorHelper.FromType(ColorType.SystemBackground);

            //    NavigationItem.BackBarButtonItem.TintColor = ColorHelper.FromType(ColorType.Image);
            //    NavigationItem. TintColor = ColorHelper.FromType(ColorType.Image);

            // Back button

            /*
             * string backText = LangUtil.Get("InfoViewController.ButtonBack.Text");
             * string backAccessibilityLabel = backText;
             * string backAccessibilityHint = LangUtil.Get("InfoViewController.ButtonBack.Accessibility.Hint");
             * ButtonUtil.SetBackButton(btnBack, backText, backAccessibilityLabel, backAccessibilityHint);
             */
        }
        private void SetupData()
        {
            double lat = 53.2314d;
            double lon = 10.9283d;

            if (AppDelegate.current.locationManager.gpsCurrentPositionObject != null)
            {
                if (AppDelegate.current.locationManager.gpsCurrentPositionObject.gpsCoordinates.Latitude != 0)
                {
                    lat = AppDelegate.current.locationManager.gpsCurrentPositionObject.gpsCoordinates.Latitude;
                    lon = AppDelegate.current.locationManager.gpsCurrentPositionObject.gpsCoordinates.Longitude;
                }
            }

            string latitudeText  = AppDelegate.current.locationManager.gpsCurrentPositionObject.latitudeDescription;
            string longitudeText = AppDelegate.current.locationManager.gpsCurrentPositionObject.longitudeDescription;

            var dd  = AppDelegate.current.coordinateService.FormatDD(lat, lon);
            var ddm = AppDelegate.current.coordinateService.FormatDDM(lat, lon);
            var dms = AppDelegate.current.coordinateService.FormatDMS(lat, lon);
            var utm = AppDelegate.current.coordinateService.FormatUTM(lat, lon);

            settingsCoordinateFormatTableViewSource.coordinateRows.Add(new CoordianteRow
            {
                CoordinateFormat = CoordinateFormat.DD,
                Title            = LangUtil.Get("SettingsViewController.Coordinates.DD"),
                Sub1             = dd.latitudeDescription,
                Sub2             = dd.longitudeDescription
            });

            settingsCoordinateFormatTableViewSource.coordinateRows.Add(new CoordianteRow
            {
                CoordinateFormat = CoordinateFormat.DDM,
                Title            = LangUtil.Get("SettingsViewController.Coordinates.DDM"),
                Sub1             = ddm.latitudeDescription,
                Sub2             = ddm.longitudeDescription
            });

            settingsCoordinateFormatTableViewSource.coordinateRows.Add(new CoordianteRow
            {
                CoordinateFormat = CoordinateFormat.DMS,
                Title            = LangUtil.Get("SettingsViewController.Coordinates.DMS"),
                Sub1             = dms.latitudeDescription,
                Sub2             = dms.longitudeDescription
            });

            settingsCoordinateFormatTableViewSource.coordinateRows.Add(new CoordianteRow
            {
                CoordinateFormat = CoordinateFormat.UTM,
                Title            = LangUtil.Get("SettingsViewController.Coordinates.UTM"),
                Sub1             = utm.latitudeDescription,
                Sub2             = utm.longitudeDescription
            });
        }
        void SetupSectionsWithElements()
        {
            // Structure that all will be added to
            structure = new StructureDto();

            // Hendelse
            StructureSectionDto structureHendelse = structure.AddStructureSection(LangUtil.Get("Structure.Hendelse.Header"));

            structureHendelse.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Hendelse.Trafikk"), "ic_trafikk");
            structureHendelse.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Hendelse.Brann"), "ic_brann");

            // Eksakt posisjon
            StructureSectionDto structureEksaktPosisjon = structure.AddStructureSection(LangUtil.Get("Structure.EksaktPosisjon.Header"));

            structureEksaktPosisjon.AddStructureElement(StructureElementDto.ElementType.Position, LangUtil.Get("Structure.EksaktPosisjon.Posisjon"), "ic_posisjon");
            structureEksaktPosisjon.AddStructureElement(StructureElementDto.ElementType.Address, LangUtil.Get("Structure.EksaktPosisjon.Adresse"), "ic_adresse");
            structureEksaktPosisjon.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.EksaktPosisjon.Oppmotested"), "ic_oppmotested");
            structureEksaktPosisjon.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.EksaktPosisjon.Ankomst"), "ic_ankomst");
            structureEksaktPosisjon.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.EksaktPosisjon.Avreise"), "ic_avreise");

            // Nivå
            StructureSectionDto structureNiva = structure.AddStructureSection(LangUtil.Get("Structure.Niva.Header"));

            structureNiva.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Niva.1"), "ic_1");
            structureNiva.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Niva.2"), "ic_2");
            structureNiva.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Niva.3"), "ic_3");
            structureNiva.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Niva.QuattroVarsling"), "ic_quattro");

            // Sikkerhet
            StructureSectionDto structureSikkerhet = structure.AddStructureSection(LangUtil.Get("Structure.Sikkerhet.Header"));

            structureSikkerhet.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Sikkerhet.Farer"), "ic_farer");
            structureSikkerhet.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Sikkerhet.Brann"), "ic_brann");
            structureSikkerhet.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Sikkerhet.Sikkerhet"), "ic_sikkerhet");

            // Pasienter
            StructureSectionDto structurePasienter = structure.AddStructureSection(LangUtil.Get("Structure.Pasienter.Header"));

            structurePasienter.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Pasienter.Antall"), "ic_pasienter");
            structurePasienter.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Pasienter.Type"), "ic_skader");
            structurePasienter.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Pasienter.Omfang"), "ic_skademekanikk");

            // Evakuering
            StructureSectionDto structureEvakuering = structure.AddStructureSection(LangUtil.Get("Structure.Evakuering.Header"));

            structureEvakuering.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Evakuering.Flaskehalser"), "ic_flaskehalser");
            structureEvakuering.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Evakuering.Kjeder"), "ic_evakuering");
            structureEvakuering.AddStructureElement(StructureElementDto.ElementType.Normal, LangUtil.Get("Structure.Evakuering.Rett"), "ic_rett");

            structure.currentStructureSectionId = 0;
        }
        private void ShowActivityIndicatorForNext(NextType nextType)
        {
            btnNext.Hidden = false;

            if (nextType == NextType.Next)
            {
                btnSkip.Hidden = false;
                btnNext.SetTitle(LangUtil.Get("Initial.Next") + "", UIControlState.Normal);
            }
            else if (nextType == NextType.Finished)
            {
                btnSkip.Hidden = true;
                btnNext.SetTitle(LangUtil.Get("Initial.Finished"), UIControlState.Normal);
            }
        }
示例#7
0
 public void UpdateAddress()
 {
     if (AppDelegate.current.locationManager.gpsCurrentPositionObject == null || AppDelegate.current.locationManager.gpsCurrentPositionObject.latitudeDescription == null)
     {
         labAddressLine1.Text = LangUtil.Get("GPS.UnknownAddress");
         labAddressLine2.Text = string.Empty;
     }
     else
     {
         Task.Run(async() =>
         {
             var coords = AppDelegate.current.locationManager.gpsCurrentPositionObject.gpsCoordinates;
             await SetAddress(coords.Latitude, coords.Longitude);
         });
     }
 }
        private void TellThatUserNeedNetworkAtFirstRun()
        {
            UIAlertView alert = new UIAlertView(LangUtil.Get("Initial.Alert.NoNetwork.Title"),
                                                LangUtil.Get("Initial.Alert.NoNetwork.Message"),
                                                null,
                                                LangUtil.Get("Alert.OK"),
                                                null);

            alert.Clicked += (s, b) =>
            {
                if (b.ButtonIndex == 0)
                {
                    // OK chosen
                    //GetEvent();
                }
            };

            alert.Show();
        }
        private void SetupServicesIfNeeded()
        {
            if (servcicesInitialized == false)
            {
                noNetworkString = LangUtil.Get("Error.NoResponse");

                regEmailSMSService = new RegEmailSMSService();

                coordinateService = new CoordinateService();
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_North, LangUtil.Get("Element.North.Text"));
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_South, LangUtil.Get("Element.South.Text"));
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_East, LangUtil.Get("Element.East.Text"));
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_West, LangUtil.Get("Element.West.Text"));
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_Degrees, LangUtil.Get("Element.Degrees.Text"));
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_Minutes, LangUtil.Get("Element.Minutes.Text"));
                coordinateService.AddLanguageValue(CoordinateServiceLanguageKey.Coordinate_Seconds, LangUtil.Get("Element.Seconds.Text"));
                servcicesInitialized = true;
            }
        }
示例#10
0
        public void SetContent()
        {
            btnMap.SetTitle(LangUtil.Get("Structure.EksaktPosisjon.ShareButton"), UIControlState.Normal);
            btnMap.RemoveTarget(ButtonEventHandler, UIControlEvent.TouchUpInside);
            btnMap.AddTarget(ButtonEventHandler, UIControlEvent.TouchUpInside);
            btnMap.Font = FontConst.fontLarge;
            btnMap.SetTitleColor(ColorHelper.FromType(ColorType.Link), UIControlState.Normal);
            BackgroundColor = UIColor.Clear;

            imgImageView.Image     = UIImage.FromBundle("ic_adresse");
            imgImageView.TintColor = ColorHelper.FromType(ColorType.Icon);

            labAddressLine1.TextColor = ColorHelper.FromType(ColorType.Link);
            labAddressLine2.TextColor = ColorHelper.FromType(ColorType.Link);

            labAddressLine1.Font = FontConst.fontLarge;
            labAddressLine2.Font = FontConst.fontLarge;

            UpdateAddress();
        }
示例#11
0
        private void UpdatePosition(UILabel labLabelBottom)
        {
            labLabelBottom.Text = LangUtil.Get("GPS.UnknownPosition");

            if (AppDelegate.current.locationManager.gpsCurrentPositionObject != null)
            {
                string latitudeText  = AppDelegate.current.locationManager.gpsCurrentPositionObject.latitudeDescription;
                string longitudeText = AppDelegate.current.locationManager.gpsCurrentPositionObject.longitudeDescription;
                //string accuracySmall = LangUtil.Get("") + ": " + AppDelegate.current.gpsCurrentPositionObject.accuracy + " " + LangUtil.Get("Location.Element.Meters.Text");

                string newPositionText = latitudeText + "\n" + longitudeText;

                lastPositionText = FlashTextUtil.FlashChangedText(lastPositionText, newPositionText, labLabelBottom, FlashTextUtil.Type.Position);
            }
            else
            {
                lastPositionText    = LangUtil.Get("GPS.UnknownPosition");
                labLabelBottom.Text = lastPositionText;
            }
        }
        public override UIView GetViewForHeader(UITableView tableView, nint section)
        {
            CGRect headerframe = new CGRect(0, 0, tableView.Bounds.Size.Width, headerHeight);
            UIView headerView  = new UIView(headerframe);

            headerView.BackgroundColor = ColorHelper.FromType(ColorType.SystemGroupedBackground);

            int labelHeight = 20;

            CGRect  labelframe = new CGRect(12, headerHeight - labelHeight - 2, tableView.Bounds.Size.Width - 10, labelHeight);
            UILabel label      = new UILabel(labelframe);

            label.Font      = FontConst.fontHeadingTable;
            label.TextColor = ColorHelper.FromType(ColorType.Label);

            if (section == coordinatsSection)
            {
                label.Text = LangUtil.Get("SettingsViewController.Coordinates.Header").ToUpper();
            }
            else if (section == locationSection)
            {
                label.Text = LangUtil.Get("SettingsViewController.Location.Header").ToUpper();
            }
            else if (section == informationSection)
            {
                label.Text = LangUtil.Get("SettingsViewController.Information.Header").ToUpper();
            }
            else if (section == concentSection)
            {
                label.Text = LangUtil.Get("SettingsViewController.Concent.Header").ToUpper();
            }
            else
            {
                label.Text = "";
            }

            headerView.AddSubview(label);
            return(headerView);
        }
        private LOTAnimationView ChangeAnimationView(int index)
        {
            int start = 0;
            int stop  = 0;

            if (index >= 2)
            {
                ShowActivityIndicatorForNext(NextType.Finished);
            }
            else
            {
                ShowActivityIndicatorForNext(NextType.Next);
            }

            if (index != 3)
            {
                InvokeOnMainThread(() =>
                {
                    labDescription.Alpha = 1.0f;
                    UIView.AnimateAsync(0.2, () =>
                    {
                        labDescription.Alpha = 0.0f;
                        View.LayoutSubviews(); // <- Dette er moder-objektet til txtEmail
                    });
                });
            }

            switch (index)
            {
            case 0:
                start = 0;
                stop  = 125;
                break;

            case 1:
                start = 125;
                stop  = 199;
                break;

            case 2:
                start = 199;
                stop  = 270;
                break;

            case 3:
                start = 270;
                stop  = 318;
                break;
            }
            //    animation.BackgroundColor = UIColor.FromRGBA(50, 50, 50, 40);

            animation.PlayFromFrame(start, stop, (animationFinished) =>
            {
                if (index == 2)
                {
                    ChangeAnimationView(3);
                }

                if (index != 3)
                {
                    switch (index)
                    {
                    case 0:
                        labDescription.Text = LangUtil.Get("Initial.PageOne.Text");
                        break;

                    case 1:
                        labDescription.Text = LangUtil.Get("Initial.PageTwo.Text");
                        break;

                    case 2:
                        labDescription.Text = LangUtil.Get("Initial.PageThree.Text");
                        break;
                    }

                    InvokeOnMainThread(() =>
                    {
                        labDescription.Alpha = 0.0f;
                        UIView.AnimateAsync(0.2, () =>
                        {
                            labDescription.Alpha = 1.0f;
                            View.LayoutSubviews();              // <- Dette er moder-objektet til txtEmail
                        });
                    });
                }
            });

            var newView = animation;

            //    animation.TranslatesAutoresizingMaskIntoConstraints = false;
            //      animation.ContentMode = UIViewContentMode.ScaleAspectFit;
            //    animation.Frame = new CoreGraphics.CGRect(0, 0, this.viewAnimation.Bounds.Size.Width, this.viewAnimation.Bounds.Size.Height);

            /*
             * if (index > 0)
             * {
             *  var oldView = _animations[index - 1];
             *  oldView.RemoveFromSuperview();
             * }
             * var newView = _animations[index];
             * newView.ContentMode = UIViewContentMode.ScaleAspectFit;
             *
             * _animation1.TranslatesAutoresizingMaskIntoConstraints = false;
             * viewAnimation.AddSubview(newView);
             *
             * var views = new NSMutableDictionary();
             * views.Add(new NSString("animationView"), newView);
             * var constraintsH = NSLayoutConstraint.FromVisualFormat("H:|-[animationView]-|", NSLayoutFormatOptions.AlignAllTop, null, views);
             * var constraintsV = NSLayoutConstraint.FromVisualFormat("V:|-[animationView]-|", NSLayoutFormatOptions.AlignAllLeft, null, views);
             * NSLayoutConstraint.ActivateConstraints(constraintsH);
             * NSLayoutConstraint.ActivateConstraints(constraintsV);
             */
            return(newView);
        }
        public override UITableViewCell GetCell(UITableView tableView, NSIndexPath indexPath)
        {
            UITableViewCell cell = null;

            string cellIdentifier;

            cellIdentifier = GetCellName(indexPath);

            if (indexPath.Section == coordinatsSection)
            {
                SettingsCoordinatesTableCell settingsCoordinatesTableCell = tableView.DequeueReusableCell(cellIdentifier) as SettingsCoordinatesTableCell;

                settingsCoordinatesTableCell.BackgroundColor   = ColorHelper.FromType(ColorType.SecondarySystemGroupedBackground);
                settingsCoordinatesTableCell.LabInfo.TextColor = ColorHelper.FromType(ColorType.Label);
                settingsCoordinatesTableCell.LabInfo.Text      = LangUtil.Get("SettingsViewController.Coordinates.Info");
                settingsCoordinatesTableCell.LabInfo.Font      = FontConst.fontSmall;

                string           coordinateButtonText = "";
                CoordinateFormat coordinateFormat     = UserUtil.Current.format;

                if (coordinateFormat == CoordinateFormat.DD)
                {
                    coordinateButtonText = LangUtil.Get("SettingsViewController.Coordinates.DD");
                }
                else if (coordinateFormat == CoordinateFormat.DDM)
                {
                    coordinateButtonText = LangUtil.Get("SettingsViewController.Coordinates.DDM");
                }
                else if (coordinateFormat == CoordinateFormat.DMS)
                {
                    coordinateButtonText = LangUtil.Get("SettingsViewController.Coordinates.DMS");
                }
                else if (coordinateFormat == CoordinateFormat.UTM)
                {
                    coordinateButtonText = LangUtil.Get("SettingsViewController.Coordinates.UTM");
                }
                else
                {
                    coordinateButtonText = LangUtil.Get("SettingsViewController.Coordinates.DDM");
                }

                settingsCoordinatesTableCell.LabValue.TextColor = ColorHelper.FromType(ColorType.Label);
                settingsCoordinatesTableCell.LabValue.Text      = coordinateButtonText;
                settingsCoordinatesTableCell.LabValue.Font      = FontConst.fontMediumRegular;


                settingsCoordinatesTableCell.BackgroundColor = ColorHelper.FromType(ColorType.SecondarySystemGroupedBackground);

                cell = settingsCoordinatesTableCell;
            }
            else if (indexPath.Section == locationSection)
            {
                // Location
                LocationServiceAccess     locationServiceAccess     = AppDelegate.current.locationManager.GetLocationServiceAccess();
                SettingsLocationTableCell settingsLocationTableCell = tableView.DequeueReusableCell(cellIdentifier) as SettingsLocationTableCell;

                settingsLocationTableCell.LabInfo.Text = LangUtil.Get("SettingsViewController.Location.Info");

                settingsLocationTableCell.LabLeft.Text = LangUtil.Get("SettingsViewController.Location.Text");

                if (locationServiceAccess == LocationServiceAccess.always)
                {
                    settingsLocationTableCell.LabRight.Text = LangUtil.Get("SettingsViewController.Location.Always");
                }
                else if (locationServiceAccess == LocationServiceAccess.onlyWhenInUse)
                {
                    settingsLocationTableCell.LabRight.Text = LangUtil.Get("SettingsViewController.Location.OnlyWhenInUse");
                }
                else if (locationServiceAccess == LocationServiceAccess.notAllowed)
                {
                    settingsLocationTableCell.LabRight.Text = LangUtil.Get("SettingsViewController.Location.NotAllowed");
                }
                else
                {
                    settingsLocationTableCell.LabRight.Text = LangUtil.Get("SettingsViewController.Location.Unset");
                }

                //  if (locationServiceAccess == LocationServiceAccess.always)
                if (locationServiceAccess == LocationServiceAccess.onlyWhenInUse)
                {
                    settingsLocationTableCell.LabInfo.TextColor = ColorHelper.FromType(ColorType.Label);
                    settingsLocationTableCell.LabInfo.Font      = FontConst.fontSmall;

                    settingsLocationTableCell.LabLeft.TextColor = ColorHelper.FromType(ColorType.Label);
                    settingsLocationTableCell.LabLeft.Font      = FontConst.fontMediumRegular;

                    settingsLocationTableCell.LabRight.TextColor = ColorHelper.FromType(ColorType.Label);
                    settingsLocationTableCell.LabRight.Font      = FontConst.fontMediumRegular;

                    settingsLocationTableCell.BackgroundColor = ColorHelper.FromType(ColorType.SecondarySystemGroupedBackground);
                }
                else
                {
                    settingsLocationTableCell.LabInfo.TextColor = ColorHelper.FromType(ColorType.LightText);
                    settingsLocationTableCell.LabInfo.Font      = FontConst.fontSmall;

                    settingsLocationTableCell.LabLeft.TextColor = ColorHelper.FromType(ColorType.LightText);
                    settingsLocationTableCell.LabLeft.Font      = FontConst.fontMediumRegular;

                    settingsLocationTableCell.LabRight.TextColor = ColorHelper.FromType(ColorType.LightText);
                    settingsLocationTableCell.LabRight.Font      = FontConst.fontMediumRegular;

                    settingsLocationTableCell.BackgroundColor = ColorHelper.FromType(ColorType.RedBackground);
                }
                cell = settingsLocationTableCell;
            }
            else if (indexPath.Section == concentSection)
            {
                SettingsTopInfoTableCell settingsTopInfoTableCell = tableView.DequeueReusableCell(cellIdentifier) as SettingsTopInfoTableCell;
                settingsTopInfoTableCell.BackgroundColor   = UIColor.Clear;
                settingsTopInfoTableCell.LabInfo.TextColor = ColorHelper.FromType(ColorType.Label);
                settingsTopInfoTableCell.LabInfo.Font      = FontConst.fontLarge;

                if (indexPath.Section == concentSection)
                {
                    //    settingsInfoTableCell.AccessibilityLabel = LangUtil.Get("SettingsViewController.Concent.Accessibility.Label");
                    //    settingsInfoTableCell.AccessibilityHint = LangUtil.Get("SettingsViewController.Concent.Accessibility.Hint");

                    if (UserUtil.Current.consentAgreed == ConsentAgreed.True)
                    {
                        settingsTopInfoTableCell.BackgroundColor   = ColorHelper.FromType(ColorType.SecondarySystemGroupedBackground);
                        settingsTopInfoTableCell.LabInfo.TextColor = ColorHelper.FromType(ColorType.Label);
                    }
                    else
                    {
                        settingsTopInfoTableCell.BackgroundColor   = ColorHelper.FromType(ColorType.RedBackground);
                        settingsTopInfoTableCell.LabInfo.TextColor = ColorHelper.FromType(ColorType.LightText);
                    }
                }

                string text = "";

                if (indexPath.Section == informationSection)
                {
                    if (indexPath.Row == 0)
                    {
                        text = LangUtil.Get("SettingsViewController.Information.Text");
                    }
                    else if (indexPath.Row == 1)
                    {
                        text = LangUtil.Get("SettingsViewController.Information.Text2");
                    }
                }
                else if (indexPath.Section == concentSection)
                {
                    text = LangUtil.Get("SettingsViewController.Concent.Text");
                }

                settingsTopInfoTableCell.LabInfo.Text = text;
                cell = settingsTopInfoTableCell;
            }
            else if (indexPath.Section == informationSection)
            {
                SettingsInfoTableCell settingsInfoTableCell = tableView.DequeueReusableCell(cellIdentifier) as SettingsInfoTableCell;
                settingsInfoTableCell.BackgroundColor    = ColorHelper.FromType(ColorType.SecondarySystemGroupedBackground);
                settingsInfoTableCell.LabLabel.TextColor = ColorHelper.FromType(ColorType.Label);
                settingsInfoTableCell.LabLabel.Font      = FontConst.fontLarge;

                if (indexPath.Section == concentSection)
                {
                    //    settingsInfoTableCell.AccessibilityLabel = LangUtil.Get("SettingsViewController.Concent.Accessibility.Label");
                    //    settingsInfoTableCell.AccessibilityHint = LangUtil.Get("SettingsViewController.Concent.Accessibility.Hint");

                    if (UserUtil.Current.consentAgreed == ConsentAgreed.True)
                    {
                        settingsInfoTableCell.BackgroundColor    = UIColor.Clear;
                        settingsInfoTableCell.LabLabel.TextColor = ColorHelper.FromType(ColorType.Label);
                    }
                    else
                    {
                        settingsInfoTableCell.BackgroundColor    = ColorHelper.FromType(ColorType.RedBackground);
                        settingsInfoTableCell.LabLabel.TextColor = ColorHelper.FromType(ColorType.LightText);
                    }
                }

                string text = "";

                if (indexPath.Section == informationSection)
                {
                    if (indexPath.Row == 0)
                    {
                        text = LangUtil.Get("SettingsViewController.Information.Text");
                    }
                    else if (indexPath.Row == 1)
                    {
                        text = LangUtil.Get("SettingsViewController.Information.Text2");
                    }
                }
                else if (indexPath.Section == concentSection)
                {
                    text = LangUtil.Get("SettingsViewController.Concent.Text");
                }

                settingsInfoTableCell.LabLabel.Text = text;
                cell = settingsInfoTableCell;
            }

            int    lineThickness   = 1;
            CGRect bottomLineframe = new CGRect(0, cell.Frame.Height - lineThickness, tableView.Bounds.Size.Width, lineThickness);
            UIView bottomLine      = new UIView(bottomLineframe);

            bottomLine.BackgroundColor = ColorHelper.FromType(ColorType.Separator);

            CGRect topLineframe = new CGRect(0, 0, tableView.Bounds.Size.Width, lineThickness);
            UIView topLine      = new UIView(topLineframe);

            topLine.BackgroundColor = ColorHelper.FromType(ColorType.Separator);

            cell.AddSubview(bottomLine);
            cell.AddSubview(topLine);

            return(cell);
        }