Sync pause setting with the menu properly

This commit is contained in:
Jeffrey Pfau 2014-07-22 02:22:03 -07:00
parent 42041fa059
commit a7588f25bb
1 changed files with 2 additions and 0 deletions

View File

@ -172,6 +172,8 @@ void Window::setupMenu(QMenuBar* menubar) {
pause->setCheckable(true);
pause->setShortcut(tr("Ctrl+P"));
connect(pause, SIGNAL(triggered(bool)), m_controller, SLOT(setPaused(bool)));
connect(m_controller, &GameController::gamePaused, [pause]() { pause->setChecked(true); });
connect(m_controller, &GameController::gameUnpaused, [pause]() { pause->setChecked(false); });
m_gameActions.append(pause);
emulationMenu->addAction(pause);