Cleaned up Dialog GUI script