public GroupCell(UITableViewCellStyle style, string cellIdentifier) : base(style, cellIdentifier)
                {
                    Title      = new UILabel( );
                    Title.Font = Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont(ControlStylingConfig.Font_Bold, ControlStylingConfig.Medium_FontSize);
                    Title.Layer.AnchorPoint = CGPoint.Empty;
                    Title.TextColor         = Rock.Mobile.UI.Util.GetUIColor(ControlStylingConfig.Label_TextColor);
                    Title.BackgroundColor   = UIColor.Clear;
                    Title.LineBreakMode     = UILineBreakMode.TailTruncation;
                    AddSubview(Title);

                    MeetingTime      = new UILabel( );
                    MeetingTime.Font = Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Small_FontSize);
                    MeetingTime.Layer.AnchorPoint = CGPoint.Empty;
                    MeetingTime.TextColor         = Rock.Mobile.UI.Util.GetUIColor(ControlStylingConfig.Label_TextColor);
                    MeetingTime.BackgroundColor   = UIColor.Clear;
                    AddSubview(MeetingTime);

                    Distance      = new UILabel( );
                    Distance.Font = Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Small_FontSize);
                    Distance.Layer.AnchorPoint = CGPoint.Empty;
                    Distance.TextColor         = Rock.Mobile.UI.Util.GetUIColor(ControlStylingConfig.Label_TextColor);
                    Distance.BackgroundColor   = UIColor.Clear;
                    AddSubview(Distance);

                    Filters      = new UILabel( );
                    Filters.Font = Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Small_FontSize);
                    Filters.Layer.AnchorPoint = CGPoint.Empty;
                    Filters.TextColor         = Rock.Mobile.UI.Util.GetUIColor(ControlStylingConfig.Label_TextColor);
                    Filters.BackgroundColor   = UIColor.Clear;
                    AddSubview(Filters);

                    JoinButton = UIButton.FromType(UIButtonType.Custom);
                    JoinButton.TouchUpInside += (object sender, EventArgs e) => { TableSource.RowButtonClicked(RowIndex); };
                    JoinButton.Font           = Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont(PrivateControlStylingConfig.Icon_Font_Secondary, PrivateConnectConfig.GroupFinder_Join_IconSize);
                    JoinButton.SetTitle(PrivateConnectConfig.GroupFinder_JoinIcon, UIControlState.Normal);
                    JoinButton.SetTitleColor(Rock.Mobile.UI.Util.GetUIColor(ControlStylingConfig.TextField_PlaceholderTextColor), UIControlState.Normal);
                    JoinButton.Layer.AnchorPoint = CGPoint.Empty;
                    JoinButton.BackgroundColor   = UIColor.Clear;
                    JoinButton.SizeToFit( );
                    AddSubview(JoinButton);

                    Seperator = new UIView( );
                    AddSubview(Seperator);
                    Seperator.Layer.BorderWidth = 1;
                    Seperator.Layer.BorderColor = Rock.Mobile.UI.Util.GetUIColor(ControlStylingConfig.BG_Layer_Color).CGColor;
                }
Beispiel #2
0
        public void Create(object masterView, RectangleF frame)
        {
            View = PlatformView.Create( );
            View.BackgroundColor = ControlStylingConfig.BackgroundColor;
            View.AddAsSubview(masterView);

            GroupTitle = PlatformLabel.Create( );
            GroupTitle.AddAsSubview(masterView);
            GroupTitle.SetFont(ControlStylingConfig.Font_Bold, ControlStylingConfig.Large_FontSize);
            GroupTitle.TextColor     = ControlStylingConfig.TextField_ActiveTextColor;
            GroupTitle.TextAlignment = TextAlignment.Center;

            /*GroupDetailsLayer = PlatformView.Create( );
             * GroupDetailsLayer.AddAsSubview( masterView );
             * GroupDetailsLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
             * GroupDetailsLayer.BorderColor = ControlStylingConfig.BG_Layer_BorderColor;
             * GroupDetailsLayer.BorderWidth = ControlStylingConfig.BG_Layer_BorderWidth;*/

            GroupDetails = PlatformLabel.Create( );
            GroupDetails.AddAsSubview(masterView);
            GroupDetails.SetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Medium_FontSize);
            GroupDetails.TextColor = ControlStylingConfig.TextField_ActiveTextColor;


            // Name Info
            FirstNameLayer = PlatformView.Create( );
            FirstNameLayer.AddAsSubview(masterView);
            FirstNameLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            FirstNameLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            FirstNameLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            FirstName = PlatformTextField.Create( );
            FirstName.AddAsSubview(masterView);
            FirstName.SetFont(ControlStylingConfig.Font_Regular, ControlStylingConfig.Medium_FontSize);
            FirstName.PlaceholderTextColor   = ControlStylingConfig.TextField_PlaceholderTextColor;
            FirstName.Placeholder            = ConnectStrings.JoinGroup_FirstNamePlaceholder;
            FirstName.TextColor              = ControlStylingConfig.TextField_ActiveTextColor;
            FirstName.KeyboardAppearance     = KeyboardAppearanceStyle.Dark;
            FirstName.AutoCapitalizationType = AutoCapitalizationType.Words;
            FirstName.AutoCorrectionType     = AutoCorrectionType.No;


            LastNameLayer = PlatformView.Create( );
            LastNameLayer.AddAsSubview(masterView);
            LastNameLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            LastNameLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            LastNameLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            LastName = PlatformTextField.Create( );
            LastName.AddAsSubview(masterView);
            LastName.SetFont(ControlStylingConfig.Font_Regular, ControlStylingConfig.Medium_FontSize);
            LastName.PlaceholderTextColor   = ControlStylingConfig.TextField_PlaceholderTextColor;
            LastName.Placeholder            = ConnectStrings.JoinGroup_LastNamePlaceholder;
            LastName.TextColor              = ControlStylingConfig.TextField_ActiveTextColor;
            LastName.KeyboardAppearance     = KeyboardAppearanceStyle.Dark;
            LastName.AutoCapitalizationType = AutoCapitalizationType.Words;
            LastName.AutoCorrectionType     = AutoCorrectionType.No;

            SpouseNameLayer = PlatformView.Create( );
            SpouseNameLayer.AddAsSubview(masterView);
            SpouseNameLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            SpouseNameLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            SpouseNameLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            SpouseName = PlatformTextField.Create( );
            SpouseName.AddAsSubview(masterView);
            SpouseName.SetFont(ControlStylingConfig.Font_Regular, ControlStylingConfig.Medium_FontSize);
            SpouseName.PlaceholderTextColor   = ControlStylingConfig.TextField_PlaceholderTextColor;
            SpouseName.Placeholder            = ConnectStrings.JoinGroup_SpouseNamePlaceholder;
            SpouseName.TextColor              = ControlStylingConfig.TextField_ActiveTextColor;
            SpouseName.KeyboardAppearance     = KeyboardAppearanceStyle.Dark;
            SpouseName.AutoCapitalizationType = AutoCapitalizationType.Words;
            SpouseName.AutoCorrectionType     = AutoCorrectionType.No;

            // Contact Info
            EmailLayer = PlatformView.Create( );
            EmailLayer.AddAsSubview(masterView);
            EmailLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            EmailLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            EmailLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            Email = PlatformTextField.Create( );
            Email.AddAsSubview(masterView);
            Email.SetFont(ControlStylingConfig.Font_Regular, ControlStylingConfig.Medium_FontSize);
            Email.PlaceholderTextColor   = ControlStylingConfig.TextField_PlaceholderTextColor;
            Email.Placeholder            = ConnectStrings.JoinGroup_EmailPlaceholder;
            Email.TextColor              = ControlStylingConfig.TextField_ActiveTextColor;
            Email.KeyboardAppearance     = KeyboardAppearanceStyle.Dark;
            Email.AutoCapitalizationType = AutoCapitalizationType.None;
            Email.AutoCorrectionType     = AutoCorrectionType.No;

            CellPhoneLayer = PlatformView.Create( );
            CellPhoneLayer.AddAsSubview(masterView);
            CellPhoneLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            CellPhoneLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            CellPhoneLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            CellPhone = PlatformTextField.Create( );
            CellPhone.AddAsSubview(masterView);
            CellPhone.SetFont(ControlStylingConfig.Font_Regular, ControlStylingConfig.Medium_FontSize);
            CellPhone.PlaceholderTextColor   = ControlStylingConfig.TextField_PlaceholderTextColor;
            CellPhone.Placeholder            = ConnectStrings.JoinGroup_CellPhonePlaceholder;
            CellPhone.TextColor              = ControlStylingConfig.TextField_ActiveTextColor;
            CellPhone.KeyboardAppearance     = KeyboardAppearanceStyle.Dark;
            CellPhone.AutoCapitalizationType = AutoCapitalizationType.None;
            CellPhone.AutoCorrectionType     = AutoCorrectionType.No;


            // Join Button
            JoinButton = PlatformButton.Create( );
            JoinButton.AddAsSubview(masterView);
            JoinButton.ClickEvent      = JoinClicked;
            JoinButton.BackgroundColor = ControlStylingConfig.Button_BGColor;
            JoinButton.TextColor       = ControlStylingConfig.Button_TextColor;
            JoinButton.CornerRadius    = ControlStylingConfig.Button_CornerRadius;
            JoinButton.Text            = ConnectStrings.JoinGroup_JoinButtonLabel;
            JoinButton.SizeToFit( );
            JoinButton.UserInteractionEnabled = true;

            // Create our results view overlay
            ResultView = new UIResultView(masterView, View.Frame, OnResultViewDone);

            // Create our blocker view
            BlockerView = new UIBlockerView(masterView, View.Frame);
        }
Beispiel #3
0
        public void Create(object masterView, RectangleF frame, OnButtonClick onJoinClicked)
        {
            OnButtonClicked = onJoinClicked;

            View = PlatformView.Create( );
            View.BackgroundColor = ControlStylingConfig.BackgroundColor;
            View.AddAsSubview(masterView);

            // Group Title
            GroupTitle = PlatformLabel.Create( );
            GroupTitle.AddAsSubview(masterView);
            GroupTitle.SetFont(ControlStylingConfig.Font_Bold, ControlStylingConfig.Large_FontSize);
            GroupTitle.TextColor     = ControlStylingConfig.TextField_ActiveTextColor;
            GroupTitle.TextAlignment = TextAlignment.Center;

            // Meeting Time
            MeetingTime = PlatformLabel.Create( );
            MeetingTime.AddAsSubview(masterView);
            MeetingTime.SetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Medium_FontSize);
            MeetingTime.TextColor     = ControlStylingConfig.TextField_ActiveTextColor;
            MeetingTime.TextAlignment = TextAlignment.Center;

            // Childcare Provided
            ChildcareProvided = PlatformLabel.Create( );
            ChildcareProvided.AddAsSubview(masterView);
            ChildcareProvided.SetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Medium_FontSize);
            ChildcareProvided.TextColor     = ControlStylingConfig.TextField_ActiveTextColor;
            ChildcareProvided.TextAlignment = TextAlignment.Center;

            // Young Adults
            YoungAdults = PlatformLabel.Create( );
            YoungAdults.AddAsSubview(masterView);
            YoungAdults.SetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Medium_FontSize);
            YoungAdults.TextColor     = ControlStylingConfig.TextField_ActiveTextColor;
            YoungAdults.TextAlignment = TextAlignment.Center;



            // Family Image and Layer
            FamilyImageLayer = PlatformView.Create( );
            FamilyImageLayer.AddAsSubview(masterView);
            FamilyImageLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            FamilyImageLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            FamilyImageLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            FamilyImage = PlatformImageView.Create( );
            FamilyImage.AddAsSubview(masterView);
            FamilyImage.ImageScaleType  = PlatformImageView.ScaleType.ScaleAspectFit;
            FamilyImage.BackgroundColor = 0;


            // Group Desc
            GroupDescLayer = PlatformView.Create( );
            GroupDescLayer.AddAsSubview(masterView);
            GroupDescLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            GroupDescLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            GroupDescLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            GroupDesc = PlatformLabel.Create( );
            GroupDesc.AddAsSubview(masterView);
            GroupDesc.TextAlignment = TextAlignment.Center;
            GroupDesc.SetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Medium_FontSize);
            GroupDesc.TextColor = ControlStylingConfig.TextField_ActiveTextColor;

            // Group Desc Header
            GroupDescHeader = PlatformLabel.Create( );
            GroupDescHeader.AddAsSubview(masterView);
            GroupDescHeader.TextAlignment = TextAlignment.Center;
            GroupDescHeader.SetFont(ControlStylingConfig.Font_Bold, ControlStylingConfig.Medium_FontSize);
            GroupDescHeader.TextColor = ControlStylingConfig.TextField_ActiveTextColor;
            GroupDescHeader.Text      = ConnectStrings.GroupInfo_AboutGroup;


            // Childcare Desc
            ChildDescLayer = PlatformView.Create( );
            ChildDescLayer.AddAsSubview(masterView);
            ChildDescLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            ChildDescLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            ChildDescLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            ChildDesc = PlatformLabel.Create( );
            ChildDesc.AddAsSubview(masterView);
            ChildDesc.SetFont(ControlStylingConfig.Font_Light, ControlStylingConfig.Medium_FontSize);
            ChildDesc.TextColor     = ControlStylingConfig.TextField_ActiveTextColor;
            ChildDesc.TextAlignment = TextAlignment.Center;

            // Child Desc Header
            ChildDescHeader = PlatformLabel.Create( );
            ChildDescHeader.AddAsSubview(masterView);
            ChildDescHeader.TextAlignment = TextAlignment.Center;
            ChildDescHeader.SetFont(ControlStylingConfig.Font_Bold, ControlStylingConfig.Medium_FontSize);
            ChildDescHeader.TextColor = ControlStylingConfig.TextField_ActiveTextColor;
            ChildDescHeader.Text      = ConnectStrings.GroupInfo_AboutChildcare;


            // Group Image and Layer
            GroupImageLayer = PlatformView.Create( );
            GroupImageLayer.AddAsSubview(masterView);
            GroupImageLayer.BackgroundColor = ControlStylingConfig.BG_Layer_Color;
            GroupImageLayer.BorderColor     = ControlStylingConfig.BG_Layer_BorderColor;
            GroupImageLayer.BorderWidth     = ControlStylingConfig.BG_Layer_BorderWidth;

            GroupImage = PlatformImageView.Create( );
            GroupImage.AddAsSubview(masterView);
            GroupImage.ImageScaleType  = PlatformImageView.ScaleType.ScaleAspectFit;
            GroupImage.BackgroundColor = 0;


            // Join Button
            JoinButton = PlatformButton.Create( );
            JoinButton.AddAsSubview(masterView);
            JoinButton.ClickEvent      = JoinClicked;
            JoinButton.BackgroundColor = ControlStylingConfig.Button_BGColor;
            JoinButton.TextColor       = ControlStylingConfig.Button_TextColor;
            JoinButton.CornerRadius    = ControlStylingConfig.Button_CornerRadius;
            JoinButton.Text            = ConnectStrings.JoinGroup_JoinButtonLabel;
            JoinButton.SizeToFit( );
            JoinButton.UserInteractionEnabled = true;

            // Create our results view overlay
            ResultView = new UIResultView(masterView, View.Frame, OnResultViewDone);

            // Create our blocker view
            BlockerView = new UIBlockerView(masterView, View.Frame);
        }