Close the savestate window, not just hiding it, when we shut things down

This commit is contained in:
Jeffrey Pfau 2014-10-18 05:07:45 -07:00
parent e2901db7c1
commit 9efd8f2452
1 changed files with 2 additions and 2 deletions

View File

@ -221,8 +221,8 @@ void Window::openStateWindow(LoadSave ls) {
}
bool wasPaused = m_controller->isPaused();
m_stateWindow = new LoadSaveState(m_controller);
connect(this, SIGNAL(shutdown()), m_stateWindow, SLOT(hide()));
connect(m_controller, SIGNAL(gameStopped(GBAThread*)), m_stateWindow, SLOT(hide()));
connect(this, SIGNAL(shutdown()), m_stateWindow, SLOT(close()));
connect(m_controller, SIGNAL(gameStopped(GBAThread*)), m_stateWindow, SLOT(close()));
connect(m_stateWindow, &LoadSaveState::closed, [this]() {
m_screenWidget->layout()->removeWidget(m_stateWindow);
m_stateWindow = nullptr;