Beispiel #1
0
void UI::popMain ()
{
	_noPushAllowed = true;
	// don't pop the root window
	while (_stack.size() > 1) {
		UIWindow* window = *_stack.rbegin();
		if (window->isMain())
			break;
		info(LOG_CLIENT, "pop window " + window->getId());
		window->onPop();
		_stack.pop_back();
		_stack.back()->onActive();

		if (window->shouldDelete()) {
			delete window;
		}
	}
	_noPushAllowed = false;
}