public void RemoveCustomTitleBar() { if (customTitleBar != null) { this.Content = customTitleBar.SetPageContent(null); customTitleBar = null; } }
public void AddCustomTitleBar() { if (customTitleBar == null) { customTitleBar = new CustomTitleBar(); customTitleBar.EnableControlsInTitleBar(areControlsInTitleBar); UIElement mainContent = this.Content; this.Content = null; customTitleBar.SetPageContent(mainContent); this.Content = customTitleBar; } }