public void ToggleToolbar() { switch (ToolbarGrid.Visibility) { case Visibility.Visible: ToolbarGrid.BeginAnimation(OpacityProperty, _gridFadeOutAnimation); break; default: ToolbarGrid.Visibility = Visibility.Visible; ChatBox.BeginAnimation(HeightProperty, _chatBoxHeightDownAnimation); break; } }
private void GridFadeOutAnimation_Completed(object sender, EventArgs e) { ToolbarGrid.Visibility = Visibility.Hidden; ChatBox.BeginAnimation(HeightProperty, _chatBoxHeightUpAnimation); }