GUI: Clean up creation of GUIs, hopefully fixing the crash-on-destroy this time.