WorkbenchWindow window = (WorkbenchWindow)PlatformUI.getWorkbench().getActiveWorkbenchWindow();
PerspectiveBarManager barManager = window.getPerspectiveBar();
CoolBarManager manager = window.getCoolBarManager();
//manager.removeAll();
MenuManager manager2 = window.getMenuBarManager();
//manager2.removeAll();
IContributionItem[] contributionItems = manager2.getItems();
for(IContributionItem item : contributionItems) {
System.out.println(item.getId());
}
manager2.remove("help");
manager.update(true);
manager2.update(true);
去掉eclipse上的菜单
最新推荐文章于 2022-04-26 10:55:18 发布