當前位置: 首頁>>代碼示例>>Java>>正文


Java PreferenceDialog.create方法代碼示例

本文整理匯總了Java中org.eclipse.jface.preference.PreferenceDialog.create方法的典型用法代碼示例。如果您正苦於以下問題:Java PreferenceDialog.create方法的具體用法?Java PreferenceDialog.create怎麽用?Java PreferenceDialog.create使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.eclipse.jface.preference.PreferenceDialog的用法示例。


在下文中一共展示了PreferenceDialog.create方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: execute

import org.eclipse.jface.preference.PreferenceDialog; //導入方法依賴的package包/類
@Execute
	public void execute(@Named(IServiceConstants.ACTIVE_SHELL) Shell shell,  E4PreferenceRegistry prefReg, 
			@Optional @Named("preferencePageId") String pageId)
	{
		PreferenceManager pm = prefReg.getPreferenceManager();
		PreferenceDialog dialog = new PreferenceDialog(shell, pm);
		if (pageId != null)
		{
			dialog.setSelectedNode(pageId);
		}

		dialog.create();
		dialog.getTreeViewer().setComparator(new ViewerComparator());
//		dialog.getTreeViewer().expandAll();
		dialog.open();
		
	}
 
開發者ID:cplutte,項目名稱:bts,代碼行數:18,代碼來源:E4PreferencesHandler.java

示例2: showPreferencePage

import org.eclipse.jface.preference.PreferenceDialog; //導入方法依賴的package包/類
protected boolean showPreferencePage()
{
    Trace.trace(Trace.CONFIG, "JettyRuntimeComposite: showPreferencePage()");

    String id = "org.eclipse.jdt.debug.ui.preferences.VMPreferencePage";

    // should be using the following API, but it only allows a single
    // preference page instance.
    // see bug 168211 for details
    // PreferenceDialog dialog =
    // PreferencesUtil.createPreferenceDialogOn(getShell(), id, new String[]
    // { id }, null);
    // return (dialog.open() == Window.OK);

    PreferenceManager manager = PlatformUI.getWorkbench().getPreferenceManager();
    IPreferenceNode node = manager.find("org.eclipse.jdt.ui.preferences.JavaBasePreferencePage").findSubNode(id);
    PreferenceManager manager2 = new PreferenceManager();
    manager2.addToRoot(node);
    PreferenceDialog dialog = new PreferenceDialog(getShell(),manager2);
    dialog.create();
    return (dialog.open() == Window.OK);
}
 
開發者ID:bengalaviz,項目名稱:JettyWTPPlugin,代碼行數:23,代碼來源:JettyRuntimeComposite.java

示例3: execute

import org.eclipse.jface.preference.PreferenceDialog; //導入方法依賴的package包/類
@Execute
public void execute(MApplication app) {
	PreferenceManager pm = configurePreferences();
	PreferenceDialog dialog = new PreferenceDialog(shell, pm);
	dialog.setPreferenceStore(new ScopedPreferenceStore(
			InstanceScope.INSTANCE, "org.bbaw.bts.app"));
	dialog.create();
	dialog.getTreeViewer().setComparator(new ViewerComparator());
	dialog.getTreeViewer().expandAll();
	dialog.open();
}
 
開發者ID:cplutte,項目名稱:bts,代碼行數:12,代碼來源:ShowPreferenceDialogHandler.java

示例4: execute

import org.eclipse.jface.preference.PreferenceDialog; //導入方法依賴的package包/類
@Execute
public void execute(@Named(IServiceConstants.ACTIVE_SHELL) Shell shell,  E4PreferenceRegistry prefReg)
{
	PreferenceManager pm = prefReg.getPreferenceManager();
	PreferenceDialog dialog = new PreferenceDialog(shell, pm);
	dialog.create();
	dialog.getTreeViewer().setComparator(new ViewerComparator());
	dialog.getTreeViewer().expandAll();
	dialog.open();
}
 
開發者ID:opcoach,項目名稱:e4Preferences,代碼行數:11,代碼來源:E4PreferencesHandler.java

示例5: showConfigDialog

import org.eclipse.jface.preference.PreferenceDialog; //導入方法依賴的package包/類
static void showConfigDialog() {
    IWorkbenchWindow window = EFActivator.getDefault().getWorkbench().getActiveWorkbenchWindow();
    IPreferencePage page = new EFPreferencePage();
    PreferenceManager mgr = window.getWorkbench().getPreferenceManager();

    Shell shell = EFActivator.getDefault().getWorkbench().getDisplay().getActiveShell();
    PreferenceDialog dialog = new PreferenceDialog(shell, mgr);
    dialog.setSelectedNode("Externalfilter.preferences.ExternalFilterPreferencePage");
    dialog.create();
    dialog.setMessage(page.getTitle());
    dialog.open();
}
 
開發者ID:mihnita,項目名稱:external-filter,代碼行數:13,代碼來源:EFToolsDynamicMenu.java


注:本文中的org.eclipse.jface.preference.PreferenceDialog.create方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。