mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 15:10:43 +07:00
IDEA-298038: avoid complete clearing of appmenu
GitOrigin-RevId: 8b1e4110839b1e35b606af62dac211c5d782712a
This commit is contained in:
committed by
intellij-monorepo-bot
parent
9f534bbebd
commit
f39cc03d92
Binary file not shown.
@@ -265,12 +265,10 @@ Java_com_intellij_ui_mac_screenmenu_Menu_nativeRefill
|
||||
}
|
||||
} else {
|
||||
// clear Main Menu: remove all except first (AppMenu)
|
||||
id appMenu = [mainMenu numberOfItems] > 0 ? [mainMenu itemAtIndex:0] : nil;
|
||||
if (appMenu != nil) {
|
||||
[appMenu retain];
|
||||
[mainMenu removeAllItems];
|
||||
[mainMenu addItem:appMenu];
|
||||
[appMenu release];
|
||||
if ([mainMenu numberOfItems] > 0) {
|
||||
for (int i = [mainMenu numberOfItems]; i - 1 > 0; i--) {
|
||||
[mainMenu removeItemAtIndex:i - 1];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user