• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java IPreferencePageContainer类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.eclipse.jface.preference.IPreferencePageContainer的典型用法代码示例。如果您正苦于以下问题:Java IPreferencePageContainer类的具体用法?Java IPreferencePageContainer怎么用?Java IPreferencePageContainer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IPreferencePageContainer类属于org.eclipse.jface.preference包,在下文中一共展示了IPreferencePageContainer类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: performOk

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
public boolean performOk()
{
	final boolean rebuild = rebuild();
	final boolean reReconcile = needsReconcile();
	Job buildJob = new ApplyChangesAndBuildJob(Messages.ValidationPreferencePage_RebuildJobTitle, rebuild,
			reReconcile);

	IPreferencePageContainer container = getContainer();
	if (container instanceof IWorkbenchPreferenceContainer)
	{
		((IWorkbenchPreferenceContainer) container).registerUpdateJob(buildJob);
	}
	else
	{
		buildJob.schedule();
	}

	return true;
}
 
开发者ID:apicloudcom,项目名称:APICloud-Studio,代码行数:21,代码来源:ValidationPreferencePage.java


示例2: createControl

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
public Control createControl(Composite parent, IPreferencePageContainer container) {
	Composite composite= new Composite(parent, SWT.NONE);
	GridData gridData= new GridData(SWT.FILL, SWT.FILL, true, true);
	composite.setLayoutData(gridData);
	GridLayout layout= new GridLayout();
	layout.marginHeight= 0;
	layout.marginWidth= 0;
	composite.setLayout(layout);

	fEnableField= new SelectionButtonDialogField(SWT.CHECK);
	fEnableField.setLabelText(getPostSaveListenerName());
	fEnableField.doFillIntoGrid(composite, 1);

	createConfigControl(composite, container);

	return composite;
}
 
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:21,代码来源:AbstractSaveParticipantPreferenceConfiguration.java


示例3: scheduleCleanerJobIfNecessary

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
/**
 * This method has been copied from org.eclipse.xtext.builder.preferences.BuilderPreferencePage.
 */
private void scheduleCleanerJobIfNecessary(IPreferencePageContainer preferencePageContainer) {
	Map<String, ValueDifference<String>> changes = getPreferenceChanges();
	for (String key : changes.keySet()) {
		if (key.matches("^" + CompilerProperties.OUTPUT_PREFERENCE_TAG + "\\.\\w+\\."
				+ CompilerProperties.OUTPUT_PREFERENCE_TAG + "$")) {
			ValueDifference<String> difference = changes.get(key);
			scheduleCleanerJob(preferencePageContainer, difference.rightValue());
		}
	}
}
 
开发者ID:eclipse,项目名称:n4js,代码行数:14,代码来源:N4JSBuilderPreferencePage.java


示例4: scheduleCleanerJob

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
/**
 * This method has been copied from org.eclipse.xtext.builder.preferences.BuilderPreferencePage.
 */
private void scheduleCleanerJob(IPreferencePageContainer preferencePageContainer, String folderNameToClean) {
	DerivedResourceCleanerJob derivedResourceCleanerJob = cleanerProvider.get();
	derivedResourceCleanerJob.setUser(true);
	derivedResourceCleanerJob.initialize(getProject(), folderNameToClean);
	if (preferencePageContainer != null) {
		IWorkbenchPreferenceContainer container = (IWorkbenchPreferenceContainer) getContainer();
		container.registerUpdateJob(derivedResourceCleanerJob);
	} else {
		derivedResourceCleanerJob.schedule();
	}
}
 
开发者ID:eclipse,项目名称:n4js,代码行数:15,代码来源:N4JSBuilderPreferencePage.java


示例5: createPreferenceLinkArea

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
/**
 * Builds a PreferenceLinkArea if the platform supports it. On platforms
 * that do not support a PreferenceLinkArea, you will be returned an empty
 * control which has no size and does nothing.
 *
 * @return A Control that can be used to link to the preference area, if
 *         supported, or an empty control if the platform does not support
 *         preference links
 */
public static Control createPreferenceLinkArea(
    final Composite parent,
    final int style,
    final String pageId,
    final String message,
    final IPreferencePageContainer container,
    final Object pageData) {
    try {
        final Class preferenceLinkClass = Class.forName("org.eclipse.ui.dialogs.PreferenceLinkArea"); //$NON-NLS-1$
        final Class workbenchPrefContainerClass =
            Class.forName("org.eclipse.ui.preferences.IWorkbenchPreferenceContainer"); //$NON-NLS-1$

        final Constructor preferenceLinkCtor = preferenceLinkClass.getConstructor(new Class[] {
            Composite.class,
            int.class,
            String.class,
            String.class,
            workbenchPrefContainerClass,
            Object.class
        });

        final Object preferenceLinkArea = preferenceLinkCtor.newInstance(new Object[] {
            parent,
            new Integer(style),
            pageId,
            message,
            container,
            pageData
        });

        final Method getControlMethod = preferenceLinkClass.getMethod("getControl", (Class[]) null); //$NON-NLS-1$
        return (Control) getControlMethod.invoke(preferenceLinkArea, (Object[]) null);
    } catch (final Exception e) {
        return new EmptyControl(parent, style);
    }
}
 
开发者ID:Microsoft,项目名称:team-explorer-everywhere,代码行数:46,代码来源:PreferenceLinkAreaHelper.java


示例6: createControl

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
public Control createControl(Composite parent) {
	Composite composite= new Composite(parent, SWT.NONE);
	composite.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false));
   	GridLayout gridLayout= new GridLayout(2, false);
   	gridLayout.marginHeight= 0;
   	gridLayout.marginWidth= 0;
	composite.setLayout(gridLayout);

	SaveParticipantRegistry registry= JavaPlugin.getDefault().getSaveParticipantRegistry();
	SaveParticipantDescriptor[] descriptors= registry.getSaveParticipantDescriptors();

	if (descriptors.length == 0)
		return composite;

	Arrays.sort(descriptors, new Comparator<SaveParticipantDescriptor>() {
		public int compare(SaveParticipantDescriptor d1, SaveParticipantDescriptor d2) {
			return Collator.getInstance().compare(d1.getPostSaveListener().getName(), d2.getPostSaveListener().getName());
		}
	});

	IPreferencePageContainer container= fPreferencePage.getContainer();
	for (int i= 0; i < descriptors.length; i++) {
		final SaveParticipantDescriptor descriptor= descriptors[i];
		ISaveParticipantPreferenceConfiguration configuration= descriptor.createPreferenceConfiguration();
		configuration.createControl(composite, container);
		fConfigurations.add(configuration);
	}

	return composite;
}
 
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:31,代码来源:SaveParticipantConfigurationBlock.java


示例7: createPreferenceContent

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
 protected Control createPreferenceContent(final Composite composite,
     final IPreferencePageContainer preferencePageContainer) {
console.debug("BuilderPreferencePage createPreferenceContent ");
  
   return builderConfigurationBlock.createContents(composite);
 }
 
开发者ID:antlr4ide,项目名称:antlr4ide,代码行数:8,代码来源:BuilderPreferencePage.java


示例8: scheduleCleanerJobIfNecessary

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
private void scheduleCleanerJobIfNecessary(final IPreferencePageContainer preferencePageContainer) {
console.debug("BuilderPreferencePage scheduleCleanerJobIfNecessary");
  
   Map<String, ValueDifference<String>> changes = builderConfigurationBlock.getPreferenceChanges();
   for (String key : changes.keySet()) {
     if (key.matches("^" + EclipseOutputConfigurationProvider.OUTPUT_PREFERENCE_TAG + "\\.\\w+\\."
         + EclipseOutputConfigurationProvider.OUTPUT_DIRECTORY + "$")) {
       ValueDifference<String> difference = changes.get(key);
       scheduleCleanerJob(preferencePageContainer, difference.rightValue());
     }
   }
 }
 
开发者ID:antlr4ide,项目名称:antlr4ide,代码行数:13,代码来源:BuilderPreferencePage.java


示例9: scheduleCleanerJob

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
private void scheduleCleanerJob(final IPreferencePageContainer preferencePageContainer,
     final String folderNameToClean) {
console.debug("BuilderPreferencePage scheduleCleanerJob");
  
   DerivedResourceCleanerJob derivedResourceCleanerJob = cleanerProvider.get();
   derivedResourceCleanerJob.setUser(true);
   derivedResourceCleanerJob.initialize(getProject(), folderNameToClean);
   if (preferencePageContainer != null) {
     IWorkbenchPreferenceContainer container = (IWorkbenchPreferenceContainer) getContainer();
     container.registerUpdateJob(derivedResourceCleanerJob);
   } else {
     derivedResourceCleanerJob.schedule();
   }
 }
 
开发者ID:antlr4ide,项目名称:antlr4ide,代码行数:15,代码来源:BuilderPreferencePage.java


示例10: createPageControl

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
public Control createPageControl( Composite parent )
{
	propertyPage.setContainer( (IPreferencePageContainer) getContainer( ) );
	propertyPage.createControl( parent );

	return propertyPage.getControl( );
}
 
开发者ID:eclipse,项目名称:birt,代码行数:8,代码来源:PropertyPageWrapper.java


示例11: TFSGlobalProxiesControl

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
public TFSGlobalProxiesControl(
    final Composite parent,
    final int style,
    final IPreferencePageContainer preferencePageContainer) {
    super(parent, style);

    final int verticalSectionSpacing = ControlSize.convertCharHeightToPixels(this, 1) * 2;

    final GridLayout layout = SWTUtil.gridLayout(this, 2);
    layout.verticalSpacing = verticalSectionSpacing;

    SWTUtil.createLabel(this, getDisplay().getSystemImage(SWT.ICON_INFORMATION));

    final String messageFormat = Messages.getString("TFSGlobalProxiesControl.SummaryLabelTextFormat"); //$NON-NLS-1$
    final String message = MessageFormat.format(messageFormat, ProductInformation.getCurrent().toString());
    final Label label = SWTUtil.createLabel(this, SWT.WRAP, message);

    GridDataBuilder.newInstance().hGrab().hFill().wCHint(label, 80).applyTo(label);

    final boolean showHttpProxyControls =
        TFSCommonUIClientPlugin.getDefault().getProxyServiceTracker().getService() == null;

    if (showHttpProxyControls) {
        httpProxyControl = new HTTPProxyControl(this, SWT.NONE);
        AutomationIDHelper.setWidgetID(httpProxyControl, HTTP_PROXY_CONTROL);
        httpProxyControl.getGridLayout().marginHeight = 0;
        httpProxyControl.getGridLayout().marginWidth = 0;
        multiValidator.addValidatable(httpProxyControl);
        GridDataBuilder.newInstance().hGrab().hFill().hSpan(layout).applyTo(httpProxyControl);
    } else {
        httpProxyControl = null;
    }

    tfProxyControl = new TFSProxyControl(this, SWT.NONE);
    AutomationIDHelper.setWidgetID(tfProxyControl, TFS_PROXY_CONTROL);
    tfProxyControl.getGridLayout().marginHeight = 0;
    tfProxyControl.getGridLayout().marginWidth = 0;
    multiValidator.addValidatable(tfProxyControl);
    GridDataBuilder.newInstance().hGrab().hFill().hSpan(layout).applyTo(tfProxyControl);

    if (httpProxyControl != null) {
        ControlSize.align(new Alignable[] {
            httpProxyControl,
            tfProxyControl
        });
    }

    if (!showHttpProxyControls) {
        final Control linkControl =
            PreferenceLinkAreaHelper.createPreferenceLinkArea(
                this,
                SWT.NONE,
                "org.eclipse.ui.net.NetPreferences", //$NON-NLS-1$
                Messages.getString("TFSGlobalProxiesControl.ClickHereToConfigureHttp"), //$NON-NLS-1$
                preferencePageContainer,
                null);

        GridDataBuilder.newInstance().hGrab().hFill().hSpan(layout).applyTo(linkControl);
    }
}
 
开发者ID:Microsoft,项目名称:team-explorer-everywhere,代码行数:61,代码来源:TFSGlobalProxiesControl.java


示例12: getContainer

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
public IPreferencePageContainer getContainer() {
	return super.getContainer();
}
 
开发者ID:grosenberg,项目名称:fluentmark,代码行数:5,代码来源:PrefPageConvert.java


示例13: setContainer

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
public void setContainer(IPreferencePageContainer container) {
	super.setContainer(container);
}
 
开发者ID:grosenberg,项目名称:fluentmark,代码行数:5,代码来源:PrefPageConvert.java


示例14: createPreferenceContent

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
protected Control createPreferenceContent(Composite composite, IPreferencePageContainer preferencePageContainer) {
	return validatorConfigurationBlock.createContents(composite);
}
 
开发者ID:cplutte,项目名称:bts,代码行数:5,代码来源:ValidatorPreferencePage.java


示例15: createPreferenceContent

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
protected abstract Control createPreferenceContent(Composite composite,
IPreferencePageContainer preferencePageContainer);
 
开发者ID:cplutte,项目名称:bts,代码行数:3,代码来源:PropertyAndPreferencePage.java


示例16: setContainer

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
public void setContainer(IPreferencePageContainer preferencePageContainer) {
  // do nothing
}
 
开发者ID:fmoraes74,项目名称:eclipseforces,代码行数:5,代码来源:JavaPreferencesPage.java


示例17: setContainer

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
@Override
public void setContainer(IPreferencePageContainer container)
{
	super.setContainer(container);
	updateStatus();
}
 
开发者ID:apicloudcom,项目名称:APICloud-Studio,代码行数:7,代码来源:SpellingPreferencePage.java


示例18: ProjectUpdateOperation

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
public ProjectUpdateOperation(ProjectController projectController, IPreferencePageContainer container) {
    super(projectController);
}
 
开发者ID:forcedotcom,项目名称:idecore,代码行数:4,代码来源:ProjectUpdateOperation.java


示例19: createControl

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
/**
 * Creates a control that will be displayed on the Java &gt; Editor &gt; Save Participants
 * preference page to edit the details of a save participant.
 *
 * @param parent the parent composite to which to add the preferences control
 * @param container the container in which this preference configuration is displayed
 * @return the control that was added to the <code>parent</code>
 */
Control createControl(Composite parent, IPreferencePageContainer container);
 
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:10,代码来源:ISaveParticipantPreferenceConfiguration.java


示例20: createConfigControl

import org.eclipse.jface.preference.IPreferencePageContainer; //导入依赖的package包/类
/**
 * Subclasses can add specific controls
 *
 * @param parent the parent to use to add the control to
 * @param container the container showing the preferences
 */
protected void createConfigControl(Composite parent, IPreferencePageContainer container) {
	//Default has no specific controls
}
 
开发者ID:trylimits,项目名称:Eclipse-Postfix-Code-Completion,代码行数:10,代码来源:AbstractSaveParticipantPreferenceConfiguration.java



注:本文中的org.eclipse.jface.preference.IPreferencePageContainer类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java At类代码示例发布时间:2022-05-22
下一篇:
Java BytesRefHash类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap