/// <summary> /// Resets the settings. /// </summary> public void ResetSettings() { if (_isShiftUp) { UpButton.RaiseEvent(new RoutedEventArgs(ButtonBase.ClickEvent)); } if (_isSymbolMode) { SymbolButton.RaiseEvent(new RoutedEventArgs(ButtonBase.ClickEvent)); } }
public PrimaryCell( UITableViewCellStyle style, string cellIdentifier, TableSource parentTableSource ) : base(style, cellIdentifier) { SelectionStyle = UITableViewCellSelectionStyle.None; ParentTableSource = parentTableSource; BackgroundColor = UIColor.Clear; Container = new UIView( ); Container.Layer.AnchorPoint = CGPoint.Empty; Container.BackgroundColor = Theme.GetColor( Config.Instance.VisualSettings.FamilyCellStyle.BackgroundColor ); AddSubview( Container ); // setup the "Family Members" label (which goes at the top of this primary cell) FamilyMembersLabel = new UILabel( ); FamilyMembersLabel.Layer.AnchorPoint = CGPoint.Empty; FamilyMembersLabel.Font = FontManager.GetFont( Settings.General_LightFont, Config.Instance.VisualSettings.MediumFontSize ); FamilyMembersLabel.Text = Strings.FamilyInfo_FamilyMembers; Theme.StyleLabel( FamilyMembersLabel, Config.Instance.VisualSettings.LabelStyle ); FamilyMembersLabel.SizeToFit( ); // setup the Guest Family label (which goes at the bottom of this primary cell) GuestFamily = new UILabel( ); GuestFamily.Layer.AnchorPoint = CGPoint.Empty; GuestFamily.Font = FontManager.GetFont( Settings.General_LightFont, Config.Instance.VisualSettings.MediumFontSize ); GuestFamily.Text = Strings.FamilyInfo_GuestFamilies; Theme.StyleLabel( GuestFamily, Config.Instance.VisualSettings.LabelStyle ); GuestFamily.SizeToFit( ); AddFamilyMemberIcon = new SymbolButton( "", Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont( "Bh", 64 ), Strings.General_AddFamilyMember, Theme.GetColor( Config.Instance.VisualSettings.FamilyCellStyle.AddFamilyButtonBGColor ), Theme.GetColor( Config.Instance.VisualSettings.FamilyCellStyle.AddFamilyButtonTextColor ), new CGRect( 0, 0, PrimaryCell.PersonEntry.PersonEntrySize, PrimaryCell.PersonEntry.PersonEntrySize ), delegate(object sender, EventArgs e) { ParentTableSource.AddMemberToFamily( AddFamilyMemberIcon, Family.Id, Family.Name ); } ); AddFamilyMemberIcon.Layer.CornerRadius = 4; }
public FooterCell( UITableViewCellStyle style, string cellIdentifier, TableSource parentTableSource ) : base(style, cellIdentifier) { SelectionStyle = UITableViewCellSelectionStyle.None; BackgroundColor = UIColor.Clear; ParentTableSource = parentTableSource; Container = new UIView( ); Container.Layer.AnchorPoint = CGPoint.Empty; Container.BackgroundColor = Theme.GetColor( Config.Instance.VisualSettings.FamilyCellStyle.BackgroundColor ); Container.Layer.CornerRadius = 4; AddSubview( Container ); AddGuestFamilyButton = new SymbolButton( "", Rock.Mobile.PlatformSpecific.iOS.Graphics.FontManager.GetFont( "Bh", 64 ), Strings.General_AddGuestFamily, Theme.GetColor( Config.Instance.VisualSettings.FamilyCellStyle.AddFamilyButtonBGColor ), Theme.GetColor( Config.Instance.VisualSettings.FamilyCellStyle.AddFamilyButtonTextColor ), new CGRect( 0, 0, PrimaryCell.PersonEntry.PersonEntrySize, PrimaryCell.PersonEntry.PersonEntrySize ), delegate(object sender, EventArgs e) { ParentTableSource.HandleAddGuestFamily( ); } ); AddGuestFamilyButton.Layer.CornerRadius = 4; Container.AddSubview( AddGuestFamilyButton ); }