public SubscriptionsPage() { InitializeComponent(); CheckForSubscriptionUpdatesCheckBox.IsChecked = GlobalConsts.CheckForSubscriptionUpdates; GlobalConsts.HideSubscriptionsButton(); GlobalConsts.ShowHelpButton(); GlobalConsts.ShowSettingsButton(); GlobalConsts.ShowHomeButton(); GlobalConsts.ShowAboutButton(); void UpdateSize(object s, SizeChangedEventArgs e) { GridScrollViewer.Height = Subscriptions.Count * 105; GridScrollViewer.MaxHeight = GlobalConsts.GetOffset() - 165; GridScrollViewer.UpdateLayout(); } GlobalConsts.Current.SizeChanged += UpdateSize; Unloaded += (s, e) => GlobalConsts.Current.SizeChanged -= UpdateSize; SubscriptionsUpdateDelayTextBox.Text = GlobalConsts.SubscriptionsUpdateDelay.TotalMinutes.ToString(); FillSubscriptions().ConfigureAwait(false); }