当前位置: 首页>>代码示例>>Java>>正文


Java IWorkbenchConfigurer类代码示例

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


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

示例1: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
public void initialize(IWorkbenchConfigurer configurer)
{
    // save the positions of windows etc...
    configurer.setSaveAndRestore(true);

    super.initialize(configurer);
    
    Bundle ideBundle = Platform.getBundle(IDE_PLUGIN);
    declareWorkbenchImage(configurer, ideBundle, IDE.SharedImages.IMG_OBJ_PROJECT, PRJ_OBJ,
            true);
    declareWorkbenchImage(configurer, ideBundle, IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED, PRJ_OBJ_C, true);
    
    declareWorkbenchImage(configurer, ideBundle, IMG_DLGBAN_SAVEAS_DLG, SAVEAS_DLG, true);
    
    // register adapter
    IDE.registerAdapters();
}
 
开发者ID:tlaplus,项目名称:tlaplus,代码行数:18,代码来源:ApplicationWorkbenchAdvisor.java

示例2: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@SuppressWarnings("nls")
@Override
public void initialize(IWorkbenchConfigurer configurer) {
    // Per default, state is not preserved (RCP book 5.1.1)
    configurer.setSaveAndRestore(true);

    // Register adapters needed by Navigator view to display workspace files
    IDE.registerAdapters();

    // Declares all IDE-specific workbench images. This includes both "shared"
    // images (named in {@link IDE.SharedImages}) and internal images.
    configurer.declareImage(IDE.SharedImages.IMG_OBJ_PROJECT,
            RCPUtils.getImageDescriptor(YamcsStudioWorkbenchAdvisor.class, "icons/project_open.png"), true);
    configurer.declareImage(IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED,
            RCPUtils.getImageDescriptor(YamcsStudioWorkbenchAdvisor.class, "icons/project_close.png"), true);

    declareWorkbenchImages();
}
 
开发者ID:yamcs,项目名称:yamcs-studio,代码行数:19,代码来源:YamcsStudioWorkbenchAdvisor.java

示例3: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(final IWorkbenchConfigurer configurer) {
	ResourcesPlugin.getPlugin().getStateLocation();
	try {
		super.initialize(configurer);
		IDE.registerAdapters();
		configurer.setSaveAndRestore(true);

		final IDecoratorManager dm = configurer.getWorkbench().getDecoratorManager();
		dm.setEnabled("org.eclipse.pde.ui.binaryProjectDecorator", false);
		dm.setEnabled("org.eclipse.team.svn.ui.decorator.SVNLightweightDecorator", false);
		dm.setEnabled("msi.gama.application.decorator", true);
		dm.setEnabled("org.eclipse.ui.LinkedResourceDecorator", false);
		dm.setEnabled("org.eclipse.ui.VirtualResourceDecorator", false);
		dm.setEnabled("org.eclipse.xtext.builder.nature.overlay", false);
	} catch (final CoreException e) {
		// e.printStackTrace();
	}

}
 
开发者ID:gama-platform,项目名称:gama,代码行数:21,代码来源:ApplicationWorkbenchAdvisor.java

示例4: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
   public void initialize(IWorkbenchConfigurer configurer) {
super.initialize(configurer);
org.eclipse.ui.ide.IDE.registerAdapters();
declareWorkbenchImages();

boolean found = false;
String vlcLib = ManagementFactory.getRuntimeMXBean().getSystemProperties().get("vlc");
if (vlcLib != null) {
    found = true;
    NativeLibrary.addSearchPath("vlc", vlcLib);
}
if (!found) {
    found = new NativeDiscovery().discover();
}
if (!found) {
    MessageDialog.openError(PlatformUI.getWorkbench().getDisplay().getActiveShell(), "Error", "Cannot play videos.  VLC is either not installed or located in an unexpected directory.  " + "If VLC is installed in an unexpected directory you can provide the path to its library. " + "Find SynergyView.ini and add a line to the end (if not already there) starting with " + "-Dvlc= followed by the path to an installation instance of VLC's lib folder.");
}

   }
 
开发者ID:synergynet,项目名称:synergyview,代码行数:21,代码来源:ApplicationWorkbenchAdvisor.java

示例5: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	super.initialize(configurer);
	
     configurer.setSaveAndRestore(true);
     PlatformUI.getPreferenceStore().setValue(
            IWorkbenchPreferenceConstants.SHOW_TRADITIONAL_STYLE_TABS, false);
     

	// inserted: register workbench adapters
	IDE.registerAdapters();

	// inserted: register images for rendering explorer view
	final String ICONS_PATH = "icons/full/";
	final String PATH_OBJECT = ICONS_PATH + "obj16/";
	Bundle ideBundle = Platform.getBundle(IDEWorkbenchPlugin.IDE_WORKBENCH);
	declareWorkbenchImage(configurer, ideBundle,
		IDE.SharedImages.IMG_OBJ_PROJECT, PATH_OBJECT + "prj_obj.gif", true);
	declareWorkbenchImage(configurer, ideBundle,
		IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED, PATH_OBJECT + "cprj_obj.gif", true);
}
 
开发者ID:CloudScale-Project,项目名称:Environment,代码行数:22,代码来源:ApplicationWorkbenchAdvisor.java

示例6: declareWorkbenchImage

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
private void declareWorkbenchImage(IWorkbenchConfigurer configurer, Bundle ideBundle, String symbolicName,
        String path, boolean shared)
{
    URL url = ideBundle.getEntry(path);
    ImageDescriptor desc = ImageDescriptor.createFromURL(url);
    configurer.declareImage(symbolicName, desc, shared);
}
 
开发者ID:tlaplus,项目名称:tlaplus,代码行数:8,代码来源:ApplicationWorkbenchAdvisor.java

示例7: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	super.initialize(configurer);
	configurer.setSaveAndRestore(true);

	final String ICONS_PATH = "icons/full/"; //$NON-NLS-1$
	final String PATH_OBJECT = ICONS_PATH + "obj16/"; //$NON-NLS-1$
	Bundle ideBundle = Platform.getBundle(IDEWorkbenchPlugin.IDE_WORKBENCH);
	declareWorkbenchImage(configurer, ideBundle,
			IDE.SharedImages.IMG_OBJ_PROJECT, PATH_OBJECT + "prj_obj.gif", //$NON-NLS-1$
			true);
	declareWorkbenchImage(configurer, ideBundle,
			IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED, PATH_OBJECT
					+ "cprj_obj.gif", true); //$NON-NLS-1$
	declareWorkbenchImage(configurer, ideBundle,
			IDEInternalWorkbenchImages.IMG_DLGBAN_SAVEAS_DLG, PATH_OBJECT
					+ "saveas_wiz.png", false); //$NON-NLS-1$
	declareWorkbenchImage(configurer, ideBundle,
			IDE.SharedImages.IMG_OBJ_PROJECT, PATH_OBJECT + "prj_obj.gif", //$NON-NLS-1$
			true);
	declareWorkbenchImage(configurer, ideBundle,
			IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED, PATH_OBJECT
					+ "cprj_obj.gif", true); //$NON-NLS-1$

	// Force the default setting for the help (tray) button in dialogs.
	// It seems that in Windows and Linux platforms as default this value is set to true.
	// However in Mac OS X the button does not shown as default behavior.
	TrayDialog.setDialogHelpAvailable(true);
	
	// Sets the branding information
	BrandingInfo info = new BrandingInfo();
	info.setProductName(Messages.ApplicationWorkbenchAdvisor_ProductName);
	info.setProductVersion(Activator.getDefault().getBundle().getVersion().toString());
	info.setProductMainBundleID(Activator.PLUGIN_ID);
	JaspersoftStudioPlugin.getInstance().setBrandingInformation(info);
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:37,代码来源:ApplicationWorkbenchAdvisor.java

示例8: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	super.initialize(configurer);
	// make sure we always save and restore workspace state
	configurer.setSaveAndRestore(true);

	IDE.registerAdapters();
	declareWorkbenchImages();
}
 
开发者ID:heartsome,项目名称:translationstudio8,代码行数:10,代码来源:ApplicationWorkbenchAdvisor.java

示例9: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	// make sure we always save and restore workspace state
	configurer.setSaveAndRestore(true);
	
	IDE.registerAdapters();
	declareWorkbenchImages();
}
 
开发者ID:heartsome,项目名称:tmxeditor8,代码行数:9,代码来源:ApplicationWorkbenchAdvisor.java

示例10: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	super.initialize(configurer);
	configurer.setSaveAndRestore(true);

	// inserted: register workbench adapters
	IDE.registerAdapters();

	// inserted: register images for rendering explorer view
	final String ICONS_PATH = "icons/full/";
	final String PATH_OBJECT = ICONS_PATH + "obj16/";
	Bundle ideBundle = Platform.getBundle(IDEWorkbenchPlugin.IDE_WORKBENCH);
	declareWorkbenchImage(configurer, ideBundle, IDE.SharedImages.IMG_OBJ_PROJECT, PATH_OBJECT + "prj_obj.gif", true);
	declareWorkbenchImage(configurer, ideBundle, IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED, PATH_OBJECT + "cprj_obj.gif", true);
}
 
开发者ID:tobiashoppe,项目名称:stammbaum,代码行数:16,代码来源:ApplicationWorkbenchAdvisor.java

示例11: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer)
{
    super.initialize(configurer);
    configurer.setSaveAndRestore(true);

    /*
     * Project Explorer and Common Navigator fail to show projects without
     * this hack. All reports I have read are about icons not showing up but
     * in my case the navigators don't even show a project's name.
     * The override of getDefaultPageInput() is also part of the
     * workaround.
     *
     * For more details:
     * https://bugs.eclipse.org/bugs/show_bug.cgi?id=234252
     * http://help.eclipse.org/indigo/topic/org.eclipse.platform.doc.isv/guide/cnf.htm
     * http://francisu.wordpress.com/2008/05/27/magic-required-to-use-the-common-navigator-in-an-rcp-application/
     * http://stackoverflow.com/questions/10345977/showing-project-explorer-view-and-its-functionality-to-rcp
     */

    IDE.registerAdapters();

    final String ICONS_PATH = "icons/full/";
    Bundle ideBundle = Platform.getBundle(IDEWorkbenchPlugin.IDE_WORKBENCH);

    declareWorkbenchImage(configurer, ideBundle,IDE.SharedImages.IMG_OBJ_PROJECT, ICONS_PATH + "obj16/prj_obj.gif",true);
    declareWorkbenchImage(configurer, ideBundle,IDE.SharedImages.IMG_OBJ_PROJECT_CLOSED, ICONS_PATH + "obj16/cprj_obj.gif", true);
    declareWorkbenchImage(configurer, ideBundle, IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEMS_VIEW, ICONS_PATH + "eview16/problems_view.gif", true);
    declareWorkbenchImage(configurer, ideBundle, IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEMS_VIEW_ERROR, ICONS_PATH + "eview16/problems_view_error.gif", true);
    declareWorkbenchImage(configurer, ideBundle, IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEMS_VIEW_WARNING, ICONS_PATH + "eview16/problems_view_warning.gif", true);
    declareWorkbenchImage(configurer, ideBundle, IDEInternalWorkbenchImages.IMG_OBJS_ERROR_PATH, ICONS_PATH + "obj16/error_tsk.gif", true);
    declareWorkbenchImage(configurer, ideBundle, IDEInternalWorkbenchImages.IMG_OBJS_WARNING_PATH, ICONS_PATH + "obj16/warn_tsk.gif", true);

    /* End of hack. */
}
 
开发者ID:vobject,项目名称:maru,代码行数:36,代码来源:ApplicationWorkbenchAdvisor.java

示例12: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	super.initialize(configurer);
	configurer.setSaveAndRestore(false);
	if (LoggerPreference.getShowConsole()) {
		Console.show();
	}
	changeWorkbenchImages();
}
 
开发者ID:GreenDelta,项目名称:olca-app,代码行数:10,代码来源:RcpWorkbenchAdvisor.java

示例13: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize ( final IWorkbenchConfigurer configurer )
{
    super.initialize ( configurer );
    configurer.setSaveAndRestore ( true );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:7,代码来源:ApplicationWorkbenchAdvisor.java

示例14: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
@Override
public void initialize(IWorkbenchConfigurer configurer) {
	super.initialize(configurer);
}
 
开发者ID:capitalone,项目名称:Hydrograph,代码行数:5,代码来源:ApplicationWorkbenchAdvisor.java

示例15: initialize

import org.eclipse.ui.application.IWorkbenchConfigurer; //导入依赖的package包/类
/**
 * @see org.eclipse.ui.application.WorkbenchAdvisor#initialize(org.eclipse.ui.application.IWorkbenchConfigurer) <!-- begin-user-doc --> <!-- end-user-doc -->
 * @generated
 */
@Override
public void initialize(IWorkbenchConfigurer configurer) {
  super.initialize(configurer);
  configurer.setSaveAndRestore(true);
}
 
开发者ID:eclipse,项目名称:triquetrum,代码行数:10,代码来源:TriquetrumEditorAdvisor.java


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