mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-05 15:48:51 +00:00
Merge pull request #13004 from Dentomologist/menubar_update_select_state_slot_on_hotkey
MenuBar: Update checkmarked Select State Slot when hotkeys are pressed
This commit is contained in:
commit
f712ea71f1
1 changed files with 4 additions and 0 deletions
|
@ -408,6 +408,10 @@ void MenuBar::AddStateSlotMenu(QMenu* emu_menu)
|
||||||
action->setChecked(true);
|
action->setChecked(true);
|
||||||
|
|
||||||
connect(action, &QAction::triggered, this, [=, this]() { emit SetStateSlot(i); });
|
connect(action, &QAction::triggered, this, [=, this]() { emit SetStateSlot(i); });
|
||||||
|
connect(this, &MenuBar::SetStateSlot, [action, i](const int slot) {
|
||||||
|
if (slot == i)
|
||||||
|
action->setChecked(true);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue