本文整理汇总了Java中org.eclipse.ui.menus.IMenuService.releaseContributions方法的典型用法代码示例。如果您正苦于以下问题:Java IMenuService.releaseContributions方法的具体用法?Java IMenuService.releaseContributions怎么用?Java IMenuService.releaseContributions使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.eclipse.ui.menus.IMenuService
的用法示例。
在下文中一共展示了IMenuService.releaseContributions方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: dispose
import org.eclipse.ui.menus.IMenuService; //导入方法依赖的package包/类
/**
* 创建自定义的插件菜单 2012-03-07
* @return ;
*/
/*
* private MenuManager createAutoPluginMenu() { MenuManager menu = new MenuManager("asdfasd",
* "net.heartsome.cat.ts.ui.menu.plugin"); // menu = MenuManag
*
* // menu.appendToGroup(groupName, item) menu.add(helpSearchAction); return menu; }
*/
@Override
public void dispose() {
if (isDisposed) {
return;
}
isDisposed = true;
IMenuService menuService = (IMenuService) window.getService(IMenuService.class);
menuService.releaseContributions(coolbarPopupMenuManager);
coolbarPopupMenuManager.dispose();
super.dispose();
}
示例2: dispose
import org.eclipse.ui.menus.IMenuService; //导入方法依赖的package包/类
/**
* Disposes any resources and unhooks any listeners that are no longer needed. Called when the
* window is closed.
*/
public void dispose()
{
if (isDisposed)
{
return;
}
isDisposed = true;
IMenuService menuService =
(IMenuService) window.getService(IMenuService.class);
menuService.releaseContributions(coolbarPopupMenuManager);
coolbarPopupMenuManager.dispose();
getActionBarConfigurer().getStatusLineManager().remove(statusLineItem);
showInQuickMenu.dispose();
newQuickMenu.dispose();
// null out actions to make leak debugging easier
closeAction = null;
closeAllAction = null;
closeAllSavedAction = null;
closeOthersAction = null;
saveAction = null;
saveAllAction = null;
newWindowAction = null;
newEditorAction = null;
helpContentsAction = null;
helpSearchAction = null;
dynamicHelpAction = null;
aboutAction = null;
saveAsAction = null;
closePerspAction = null;
closeAllPerspsAction = null;
showViewMenuAction = null;
undoAction = null;
redoAction = null;
quitAction = null;
openWorkspaceAction = null;
projectPropertyDialogAction = null;
newWizardAction = null;
quickStartAction = null;
tipsAndTricksAction = null;
showInQuickMenu = null;
newQuickMenu = null;
statusLineItem = null;
introAction = null;
super.dispose();
}