Fixed bug where the WindowManager close method wouldn't properly close the top most window.