void ReleaseDesignerOutlets() { if (CalendarButton != null) { CalendarButton.Dispose(); CalendarButton = null; } if (FavoritesButton != null) { FavoritesButton.Dispose(); FavoritesButton = null; } if (NavBar != null) { NavBar.Dispose(); NavBar = null; } if (NutritionButton != null) { NutritionButton.Dispose(); NutritionButton = null; } if (ProfileButton != null) { ProfileButton.Dispose(); ProfileButton = null; } if (WorkoutsButton != null) { WorkoutsButton.Dispose(); WorkoutsButton = null; } }
private void InitializeStyle() { BackgroundView.BarTintColor = Background; Separator.Color = ThemeColors.HeaderBackground.GetDarker(0.4f); SortByLabel.Font = Theme.OrgEventHeaderFont; SortByLabel.TextColor = Light; SortBySegments.SetTitleTextAttributes( new UITextAttributes { Font = Theme.OrgEventHeaderFont, TextColor = Light }, UIControlState.Highlighted); SortBySegments.SetTitleTextAttributes( new UITextAttributes { Font = Theme.OrgEventHeaderFont, TextColor = Light }, UIControlState.Normal); SortBySegments.TintColor = Light; FavoritesButton.Font = Theme.OrgEventHeaderFont; FavoritesButton.SetTitleColor(Light, UIControlState.Normal); FavoritesButton.SetImage(ThemeIcons.StarSmall, UIControlState.Normal); FavoritesButton.TintColor = Light; FavoritesButton.Layer.BorderWidth = 0.9f; FavoritesButton.Layer.CornerRadius = 4; FavoritesButton.Layer.BorderColor = Light.CGColor; FavoritesButton.TouchDown += (sender, e) => FavoritesButton.BackgroundColor = ThemeColors.ContentLightBackground.ColorWithAlpha(0.2f); FavoritesButton.TouchUpInside += (sender, e) => UpdateFavoritesState(); FavoritesButton.TouchUpOutside += (sender, e) => UpdateFavoritesState(); }
private void SeutpShadows() { InfoButton.AddShadow(); OrdersButton.AddShadow(); FavoritesButton.AddShadow(); SecurityButton.AddShadow(); }
public override void AwakeFromNib() { base.AwakeFromNib(); SortBySegments.SetTitle(Localization.Name, 0); SortBySegments.SetTitle(Localization.Time, 1); SortByLabel.Text = Localization.OrderBy; // HACK: A space for a gap between start and caption FavoritesButton.SetTitle(" " + Localization.Favorites, UIControlState.Normal); InitializeStyle(); }
private void UpdateFavoritesState() { UIView.Animate(UIConstants.AnimationDuration, () => { if (ShowOnlyFavotires) { FavoritesButton.SetTitleColor(Background, UIControlState.Normal); FavoritesButton.TintColor = Background; FavoritesButton.BackgroundColor = Light; } else { FavoritesButton.SetTitleColor(Light, UIControlState.Normal); FavoritesButton.TintColor = Light; FavoritesButton.BackgroundColor = UIColor.Clear; } }); }
void ReleaseDesignerOutlets() { if (ContentView != null) { ContentView.Dispose(); ContentView = null; } if (BackgroundView != null) { BackgroundView.Dispose(); BackgroundView = null; } if (FavoritesButton != null) { FavoritesButton.Dispose(); FavoritesButton = null; } if (Separator != null) { Separator.Dispose(); Separator = null; } if (SortByLabel != null) { SortByLabel.Dispose(); SortByLabel = null; } if (SortBySegments != null) { SortBySegments.Dispose(); SortBySegments = null; } }