mirror of
https://github.com/KLayout/klayout.git
synced 2026-09-08 04:08:14 +02:00
Reworked bookmark menu implementation to avoid MacOS menu issue
Without this commit, bookmark menus got grayed out on MacOS with Qt5 sometimes. Now, the implementation of recent file menu, bookmark menu, macro menu and the static main menu use the same framewkork which includes a workaround for the disabled menu issue.
This commit is contained in:
@@ -124,5 +124,14 @@ TEST(1)
|
||||
|
||||
menu.delete_item ("n1.c2");
|
||||
EXPECT_EQ (menu_to_string (menu), "(n2)");
|
||||
}
|
||||
|
||||
menu.clear_menu ("n1");
|
||||
EXPECT_EQ (menu_to_string (menu), "(n2)");
|
||||
|
||||
menu.insert_menu ("end", "n1", lay::Action ("title:n1"));
|
||||
menu.insert_item ("n1.begin", "c1", lay::Action ("title:c1"));
|
||||
menu.insert_item ("n1.end", "c2", lay::Action ("title:c2"));
|
||||
EXPECT_EQ (menu_to_string (menu), "(n2,n1(n1.c1,n1.c2))");
|
||||
menu.clear_menu ("n1");
|
||||
EXPECT_EQ (menu_to_string (menu), "(n2,n1)");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user