Author: kono
Date: 2012-10-08 16:19:33 -0700 (Mon, 08 Oct 2012)
New Revision: 30629
Modified:
core3/support/branches/user-beta1/splash-updater-impl/src/main/java/org/cytoscape/splash/internal/SplashManipulator.java
Log:
SplashManipulator pactched.
Modified:
core3/support/branches/user-beta1/splash-updater-impl/src/main/java/org/cytoscape/splash/internal/SplashManipulator.java
===================================================================
---
core3/support/branches/user-beta1/splash-updater-impl/src/main/java/org/cytoscape/splash/internal/SplashManipulator.java
2012-10-08 22:58:38 UTC (rev 30628)
+++
core3/support/branches/user-beta1/splash-updater-impl/src/main/java/org/cytoscape/splash/internal/SplashManipulator.java
2012-10-08 23:19:33 UTC (rev 30629)
@@ -13,6 +13,8 @@
import org.osgi.framework.BundleListener;
import org.osgi.framework.FrameworkEvent;
import org.osgi.framework.FrameworkListener;
+import org.osgi.framework.ServiceReference;
+import org.osgi.service.startlevel.StartLevel;
public class SplashManipulator implements
BundleListener,
@@ -30,6 +32,8 @@
resolved = new HashSet<Long>();
started = new HashSet<Long>();
+ applyStartLevelHack();
+
for (Bundle bundle : context.getBundles()) {
long id = bundle.getBundleId();
resolved.add(id);
@@ -46,7 +50,16 @@
font = new Font(Font.MONOSPACED,Font.PLAIN,12);
}
- public void bundleChanged(BundleEvent event) {
+ private void applyStartLevelHack() {
+ // See ticket #1494. This hack needs to remain in place until Karaf
+ // is patched.
+ ServiceReference reference =
context.getServiceReference(StartLevel.class.getName());
+ StartLevel level = (StartLevel) context.getService(reference);
+ level.setStartLevel(200);
+ context.ungetService(reference);
+ }
+
+ public void bundleChanged(BundleEvent event) {
if ( event.getType() == BundleEvent.RESOLVED )
resolved.add(event.getBundle().getBundleId());
--
You received this message because you are subscribed to the Google Groups
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/cytoscape-cvs?hl=en.