commit | 1105fb3bc1fd3ea22a86a3b1da86bc056415d4c5 | [log] [tgz] |
---|---|---|
author | Christian Walther <walther@indel.ch> | Fri Apr 01 10:14:19 2016 +0200 |
committer | Thomas Watson <tjwatson@us.ibm.com> | Fri Jun 25 09:03:00 2021 -0400 |
tree | 4394b06434b9190f87eb8080af84c5aadd91838f | |
parent | b82c7eb4e77a72e7430dfc5558a9d5c2fca4da3d [diff] |
Bug 574432 - Allow applications to modify eclipse.allowAppRelaunch Change-Id: I12d93a227efbe80703d33d3473fe7c995fda0d38 Signed-off-by: Christian Walther <walther@indel.ch> Reviewed-on: https://git.eclipse.org/r/c/equinox/rt.equinox.framework/+/182400 Tested-by: Equinox Bot <equinox-bot@eclipse.org> Reviewed-by: Thomas Watson <tjwatson@us.ibm.com>
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java index e310abb..06049a0 100644 --- a/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java +++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/adaptor/EclipseStarter.java
@@ -127,7 +127,7 @@ public static final String PROP_CONSOLE_LOG = "eclipse.consoleLog"; //$NON-NLS-1$ public static final String PROP_IGNOREAPP = "eclipse.ignoreApp"; //$NON-NLS-1$ public static final String PROP_REFRESH_BUNDLES = "eclipse.refreshBundles"; //$NON-NLS-1$ - private static final String PROP_ALLOW_APPRELAUNCH = "eclipse.allowAppRelaunch"; //$NON-NLS-1$ + public static final String PROP_ALLOW_APPRELAUNCH = "eclipse.allowAppRelaunch"; //$NON-NLS-1$ private static final String PROP_APPLICATION_LAUNCHDEFAULT = "eclipse.application.launchDefault"; //$NON-NLS-1$ private static final String FILE_SCHEME = "file:"; //$NON-NLS-1$
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/internal/adaptor/EclipseAppLauncher.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/internal/adaptor/EclipseAppLauncher.java index 2836f03..8d65643 100644 --- a/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/internal/adaptor/EclipseAppLauncher.java +++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/core/runtime/internal/adaptor/EclipseAppLauncher.java
@@ -102,6 +102,8 @@ } result = runApplication(defaultContext); + // refresh the allowAppRelaunch setting in case the application changed it + relaunch = Boolean.valueOf(equinoxConfig.getConfiguration(EclipseStarter.PROP_ALLOW_APPRELAUNCH)); } catch (Exception e) { if (!relaunch || (b.getState() & Bundle.ACTIVE) == 0) throw e;