/// <summary> /// Hides the dialog window /// </summary> /// <param name="windowContents">Contents of the window displayed earlier using ShowWindow</param> public void HideWindow(FrameworkElement windowContents) { if (windowContents == null) { throw new ArgumentNullException("windowContents"); } int hashCode = windowContents.GetHashCode(); FloatingWindow floatingWindow = null; if (m_FloatingWindows.TryGetValue(hashCode, out floatingWindow)) { floatingWindow.Hide(); // close will automatically remove the window from the hash table in floatingWindow_Closed } }