eclipse-rcp

How to use groovy inside a Eclipse RCP project?

谁说我不能喝 提交于 2019-12-07 08:18:49
问题 I have a Eclipse RCP project, and I want to use Groovy inside it. what I try to do is : 1) add "Groovy Nature" 2) create Groovy files under the "src" folder 3) call the groovy class from the "View"'s createPartControl() method. But I got the “java.lang.ClassNotFoundException: fly.island.jface.Test”, and the "fly.island.jface.Test" is a groovy class. What should I do to use groovy inside the Eclipse RCP project? 回答1: Use the latest version of Groovy-Eclipse 2.1.0 (or one of the dev builds).

Tycho: Bundle X - Missing Constraint: Bundle-RequiredExecutionEnvironment: JavaSE-1.7

霸气de小男生 提交于 2019-12-07 07:35:15
问题 I have changed the BREE from JavaSE-1.6 to JavaSE-1.7 in the manifest files of my application: Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Now I can not compile the application again. When I run mvn clean install I get: [INFO] Resolving dependencies of MavenProject: Xgroup:X:4.0.100-SNAPSHOT @ C:\Users\....\X\pom.xml [WARNING] The following locally built units have been used to resolve project dependencies: [WARNING] Za [WARNING] Zb [INFO] Resolving class path of MavenProject: Xgroup:X:4

How can I add the external jar to the eclipse rcp application?

三世轮回 提交于 2019-12-07 04:47:22
问题 I tried to add the apache vfs jar file as the runtime dependency. Even though it throws the below error: java.lang.ClassNotFoundException: org.apache.commons.vfs.VFS at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:489) at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:405) at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:393) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass

Contributed control to the status bar not visible

▼魔方 西西 提交于 2019-12-07 04:29:33
问题 I would like to place a control in the status bar of the workbench window. The whole process should be straight-forward, but whatever I try, the status bar contribution does not become visible. Because I do not own the application but just contrinbute a plug-in to the IDE, WorkbenchWindowAdvisor and friends are not an option. The extension point is this: <extension point="org.eclipse.ui.menus"> <menuContribution locationURI="toolbar:org.eclipse.ui.trim.status" allPopups="false"> <control

Eclipse 4 RCP Application (standalone!): Add “show view” in menu

有些话、适合烂在心里 提交于 2019-12-07 03:06:30
In my standalone RCP Application (which I start using a product configuration) I would like to add a menu entry "show view" that lists all views I have defined in my persistent application model (an application.e4xmi file) being closed . Currently I do not have any Advisor Classes in use. What I did was to manually add HandledMenuItems for each view and added a CoreExpression as Visible-When Expression . This expression tests for a special key value pair in the application context . The problem here is that I would need a special expression for each view. What would be a good pattern to solve

Update Eclipse E4 application using p2

落花浮王杯 提交于 2019-12-07 02:07:26
I'm adding an update feature in my Eclipse E4 application. Herefor I used the source code and tutorial from Lars Vogel. When I test my application the provisioningJob is always null. It should only be null when it run into Eclipse. But when I try to update my exported application the provisioningJob is still null. What I'm doing wrong? public class UpdateHandler { private static final String REPOSITORY_LOC = System.getProperty("UpdateHandler.Repo", "file:////updateServer/repository"); @Execute public void execute(final IProvisioningAgent agent, final Shell shell, final UISynchronize sync,

IResourceChangeEvent - how to identify a project delete/rename

十年热恋 提交于 2019-12-07 02:01:17
问题 How can I properly distinguish, inside an IResourceChangeListener that is added via ResourcePlugin.getWorkspace().addResourceChangeListener(...) that a Project was deleted / renamed? Through trying things out, it would seem that the IResourceChangeEvent.getDelta() -> IResourceDelta would be the answer. From Eclipse API: After-the-fact batch reports of arbitrary creations, deletions and modifications to one or more resources expressed as a hierarchical resource delta. Event type is POST_CHANGE

Dynamic language switching in an Eclipse RCP application

心不动则不痛 提交于 2019-12-07 01:40:37
问题 I am working on an Eclipse RCP application with localization. A user should be able to change the language used in the application on the fly. A restart of the application should not take place during this language switch. It should also be possible to switch between languages written from left to right and languages written from right to left. Is there a (good) way to solve this problem? 回答1: According to this thread: Most of the eclipse libraries load up their language info on widget

Eclipse RCP: How to prevent multiple instances of RCP from launching?

我的梦境 提交于 2019-12-07 00:01:01
问题 I read on http://eclipse.geekyramblings.net/2010/12/14/preventing-multiple-instances/ on how to prevent multiple instances of your RCP from being launched. But when I made my RCP(It's a simple RCP based on the "Hello RCP" Template) executable and tried launching it, it throws me this error java.io.IOException: The location has not been set. at org.eclipse.core.runtime.internal.adaptor.BasicLocation.lock(BasicLocation.java:174) at testrcp.Application.start(Application.java:43) at org.eclipse

How to use eclipse 4 DI in classes that are not attached to the application model?

喜夏-厌秋 提交于 2019-12-06 23:10:05
问题 I have created a OSGI service with declarative services to inject an object that implements an interface. If I inject the object in a class that is attached to the application model (handler,part,....) it is working fine. If I inject it in a class that is not attached to the application model it is always returning null. Is it possible to use DI in classes that are not attached to the application model? I looked in the vogella tutorials but somehow I don't find a solution. 回答1: I know of