bool GUILobby::OnLeave() { CEGUI::Window* parent = NULL; // decide where to attach the console main window parent = parent ? parent : CEGUI::System::getSingleton().getDefaultGUIContext().getRootWindow(); // attach this window if parent is valid if (parent) parent->removeChild(d_root); return true; }
bool GUIMessageBox::handleSubmit(const CEGUI::EventArgs&) { CEGUI::Window* parent = NULL; // decide where to attach the console main window parent = parent ? parent : CEGUI::System::getSingleton().getDefaultGUIContext().getRootWindow(); // attach this window if parent is valid if (parent) parent->removeChild(d_root); delete this; return true; }