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


Java PreferencesUtil.createPropertyDialogOn方法代碼示例

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


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

示例1: run

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
public void run(final IMarker marker) {
  PreferenceDialog page = PreferencesUtil.createPropertyDialogOn(
      CorePlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell(),
      marker.getResource().getProject(), projectPropertyPageID,
      new String[] {projectPropertyPageID}, null);

  page.open();
}
 
開發者ID:gwt-plugins,項目名稱:gwt-eclipse-plugin,代碼行數:9,代碼來源:ConfigureProjectSdkMarkerResolution.java

示例2: run

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
public void run(IAction action) {
  Shell shell = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell();

  if (resource != null && resource.getType() == IResource.PROJECT) {
    PreferenceDialog page = PreferencesUtil.createPropertyDialogOn(shell,
        resource, propertiesPageID, null, null);
    if (page != null) {
      page.open();
      return;
    }
  }

  CorePluginLog.logError("Could not create project properties dialog for resource "
      + resource.toString());
}
 
開發者ID:gwt-plugins,項目名稱:gwt-eclipse-plugin,代碼行數:16,代碼來源:AbstractProjectPropertiesAction.java

示例3: run

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
/**
 * Run the command, displaying a new project properties dialog on the ZXTM
 * settings page.
 */
/* Override */
public void run( ExecutionEvent event )
{
   ZXTM currentZXTM = zxtm;
   
   // No selection, check if the ZXTM Viewer has one currently.
   if( currentZXTM == null ) {
      ModelSelection currentSelection = ZXTMViewer.getSelectionForOpenViewer();
      if( currentSelection != null && currentSelection.isOnlyOneZXTM() ) {
         currentZXTM = currentSelection.firstZXTM();
      }
   }
   
   if( currentZXTM == null ) {
      return;
   }
   
   // Display the settings page.
   IProject project = ZXTMProject.getProjectForZXTM( currentZXTM );       
   PreferenceDialog dialog = PreferencesUtil.createPropertyDialogOn( 
      Display.getCurrent().getActiveShell(), project, Ids.RES_PREFS_ZXTM, 
      null, null 
   );
   
   dialog.open();
}
 
開發者ID:brocade,項目名稱:vTM-eclipse,代碼行數:31,代碼來源:ZXTMSettingsAction.java

示例4: typePageLinkActivated

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
private void typePageLinkActivated() {
	IJavaProject project= getJavaProject();
	if (project != null) {
		PreferenceDialog dialog= PreferencesUtil.createPropertyDialogOn(getShell(), project.getProject(), CodeTemplatePreferencePage.PROP_ID, null, null);
		dialog.open();
	} else {
		String title= NewWizardMessages.NewTypeWizardPage_configure_templates_title;
		String message= NewWizardMessages.NewTypeWizardPage_configure_templates_message;
		MessageDialog.openInformation(getShell(), title, message);
	}
}
 
開發者ID:trylimits,項目名稱:Eclipse-Postfix-Code-Completion,代碼行數:12,代碼來源:NewTypeWizardPage.java

示例5: handle

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
@Override
public void handle() {
	PreferenceDialog propertyDialog = PreferencesUtil.createPropertyDialogOn(getShell(),
		requireSelection(ProjectSpace.class).getProject(), null, null, null);
	if (propertyDialog != null) {
		propertyDialog.open();
	}
}
 
開發者ID:edgarmueller,項目名稱:emfstore-rest,代碼行數:9,代碼來源:ProjectPropertiesHandler.java

示例6: handleStatus

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
@Override
public Object handleStatus(IStatus status, Object source)
		throws CoreException {
	HybridMobileStatus  hs = (HybridMobileStatus) status;
	
	final boolean open = MessageDialog.openQuestion(AbstractStatusHandler.getShell(), "Missing or incomplete Hybrid Mobile Engine", 
			NLS.bind("{0} \n\nWould you like to modify Hybrid Mobile Engine preferences to correct this issue?",hs.getMessage() ));
	
	if(open){
		PreferenceDialog dialog = PreferencesUtil.createPropertyDialogOn(getShell(), hs.getProject(), 
				EnginePropertyPage.PAGE_ID, new String[]{EnginePropertyPage.PAGE_ID}, null);
		return (dialog != null && dialog.open() == Window.OK)? Boolean.TRUE: Boolean.FALSE; 
	}
	return Boolean.FALSE;
}
 
開發者ID:eclipse,項目名稱:thym,代碼行數:16,代碼來源:EngineStatusHandler.java

示例7: runAction

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
protected static void runAction(IBreakpoint breakpoint, IShellProvider shell) {
  PreferenceDialog propertyDialog = PreferencesUtil.createPropertyDialogOn(
      shell.getShell(), breakpoint, (String) null, (String[]) null, null);

  propertyDialog.open();
}
 
開發者ID:jbosstools,項目名稱:chromedevtools,代碼行數:7,代碼來源:JsBreakpointPropertiesAction.java

示例8: doRun

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
@Override
public void doRun() throws StatusException {
	PreferenceDialog dialog = PreferencesUtil.createPropertyDialogOn(getShell(), getProject(), 
		getProjectConfigPropertyPage(), null, targetName);
	dialog.open();
}
 
開發者ID:GoClipse,項目名稱:goclipse,代碼行數:7,代碼來源:BuildTargetsActionGroup.java

示例9: createContextMenu

import org.eclipse.ui.dialogs.PreferencesUtil; //導入方法依賴的package包/類
private void createContextMenu()
{
	copyAction = new Action()
	{
		@Override
		public void run()
		{
			if (selection.isEmpty()) return;
			
			ObjectData data = (ObjectData) getSelection().getFirstElement();
			setTemplate(getTemplateFromObject(ObjectUtil.clone(data)));
			ClipboardUtil.toClipboard(selection);
		}
	};
	copyAction.setText("Kopieren");
	copyAction.setAccelerator(SWT.CONTROL | 'c');
	copyAction.setImageDescriptor(getSharedImageDescriptor(ISharedImages.IMG_TOOL_COPY));

	pasteAction = new Action()
	{
		@Override
		public void run()
		{
			IStructuredSelection s = ClipboardUtil.fromClipboard();
			if (s.isEmpty() || !(s.getFirstElement() instanceof ObjectData)) return;
			
			selection = s;
		}
	};
	pasteAction.setText("Einfügen");
	pasteAction.setAccelerator(SWT.CONTROL | 'v');
	pasteAction.setImageDescriptor(getSharedImageDescriptor(ISharedImages.IMG_TOOL_PASTE));
	
	deleteAction = new Action()
	{
		@Override
		public void run()
		{
			for(Object obj : selection.toArray())
			{
				int id = ((ObjectData) obj).id;
				map.objects.remove(id);
			}
			setSelection(null);
		}
	};
	deleteAction.setText("Entfernen");
	deleteAction.setAccelerator(SWT.CONTROL | 'v');
	deleteAction.setImageDescriptor(getSharedImageDescriptor(ISharedImages.IMG_TOOL_DELETE));
	
	propertyAction = new Action()
	{
		@Override
		public void run()
		{
			if (selection.isEmpty()) return;
			
			ObjectData obj = (ObjectData) selection.getFirstElement();
			if (obj == null) return;
			
			ObjectAdapter adapter = new ObjectAdapter(editor.getProject(), obj);

			PreferenceDialog dialog = PreferencesUtil.createPropertyDialogOn(
					editor.getGLCanvas().getShell(), adapter, ObjectBasePropertyPage.ID, null, adapter);
			if (dialog != null) dialog.open();
		}
	};
	propertyAction.setText("Eigenschaften");
}
 
開發者ID:TheWhiteShadow3,項目名稱:cuina,代碼行數:70,代碼來源:ObjectLayer.java


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