Fix some menu bar items unresponsive after language change

This commit is contained in:
Haoyu Qiu
2025-06-15 13:21:31 +08:00
parent 46c495ca21
commit 51e8b5947f

View File

@ -320,12 +320,18 @@ void MenuBar::_notification(int p_what) {
} }
} }
} }
if (!is_global) {
update_minimum_size();
}
} break; } break;
case NOTIFICATION_LAYOUT_DIRECTION_CHANGED: case NOTIFICATION_LAYOUT_DIRECTION_CHANGED:
case NOTIFICATION_THEME_CHANGED: { case NOTIFICATION_THEME_CHANGED: {
for (int i = 0; i < menu_cache.size(); i++) { for (int i = 0; i < menu_cache.size(); i++) {
shape(menu_cache.write[i]); shape(menu_cache.write[i]);
} }
if (global_menu_tag.is_empty()) {
update_minimum_size();
}
} break; } break;
case NOTIFICATION_VISIBILITY_CHANGED: { case NOTIFICATION_VISIBILITY_CHANGED: {
if (is_native_menu()) { if (is_native_menu()) {