Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDEHelper.java8
-rw-r--r--org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDETargetPlatformWizardFragment.java4
2 files changed, 10 insertions, 2 deletions
diff --git a/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDEHelper.java b/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDEHelper.java
index 19555f5..9b559b6 100644
--- a/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDEHelper.java
+++ b/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDEHelper.java
@@ -310,9 +310,15 @@ public final class PDEHelper {
Properties added = new Properties();
int count = 0;
+ IPath virgoHome = runtime.getLocation();
+
for (File file : newFoldersSet) {
+ IPath path = new Path(file.getCanonicalPath());
+ if (virgoHome.isPrefixOf(path)) {
+ path = path.removeFirstSegments(virgoHome.segmentCount());
+ }
added.put(ADDED_BY_VIRGO_TOOLS + count + REPO_TYPE, TYPE_WATCHED);
- added.put(ADDED_BY_VIRGO_TOOLS + count + WATCH_DIRECTORY, file.getCanonicalPath());
+ added.put(ADDED_BY_VIRGO_TOOLS + count + WATCH_DIRECTORY, path.toString());
count++;
}
diff --git a/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDETargetPlatformWizardFragment.java b/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDETargetPlatformWizardFragment.java
index 550eced..f190c05 100644
--- a/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDETargetPlatformWizardFragment.java
+++ b/org.eclipse.virgo.ide.runtime.ui/src/org/eclipse/virgo/ide/runtime/internal/ui/PDETargetPlatformWizardFragment.java
@@ -77,6 +77,8 @@ public class PDETargetPlatformWizardFragment extends WizardFragment {
*/
@Override
public void performFinish(IProgressMonitor monitor) throws CoreException {
- targetPlatformComposite.performFinish(monitor);
+ if (targetPlatformComposite != null) {
+ targetPlatformComposite.performFinish(monitor);
+ }
}
}

Back to the top