private void MinimizeAnim_Completed(object sender, EventArgs e) { this.BeginAnimation(HeightProperty, null); this.Height = ((DoubleAnimation)this.Resources["MinimizeAnim"]).To.GetValueOrDefault(); if (tileObject != null) { tileObject.IsMinimized = true; tileObject.Minimized(); } headerState = Header.Visibility; Header.Visibility = Visibility.Visible; this.minimized = true; }