mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
win: Update menu states when setting menu bar.
This commit is contained in:
@@ -415,6 +415,7 @@ void NativeWindowWin::OnMenuCommand(int position, HMENU menu) {
|
||||
|
||||
void NativeWindowWin::SetMenu(ui::MenuModel* menu_model) {
|
||||
menu_.reset(new atom::Menu2(menu_model, true));
|
||||
menu_->UpdateStates();
|
||||
::SetMenu(GetNativeWindow(), menu_->GetNativeMenu());
|
||||
RegisterAccelerators();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user