Author: yradtsevich
Date: 2011-11-24 14:43:13 -0500 (Thu, 24 Nov 2011)
New Revision: 36622
Modified:
trunk/vpe/plugins/org.jboss.tools.xulrunner.initializer/src/org/eclipse/swt/browser/BrowserInitializer.java
Log:
https://issues.jboss.org/browse/JBIDE-10185 : Installing JBoss Tools 3.3 into Eclipse
causes some problems for the Welcome screen
Modified:
trunk/vpe/plugins/org.jboss.tools.xulrunner.initializer/src/org/eclipse/swt/browser/BrowserInitializer.java
===================================================================
---
trunk/vpe/plugins/org.jboss.tools.xulrunner.initializer/src/org/eclipse/swt/browser/BrowserInitializer.java 2011-11-24
15:42:08 UTC (rev 36621)
+++
trunk/vpe/plugins/org.jboss.tools.xulrunner.initializer/src/org/eclipse/swt/browser/BrowserInitializer.java 2011-11-24
19:43:13 UTC (rev 36622)
@@ -1,13 +1,22 @@
package org.eclipse.swt.browser;
+import org.eclipse.core.runtime.Platform;
+
public class BrowserInitializer {
private static final String PROPERTY_DEFAULTTYPE =
"org.eclipse.swt.browser.DefaultType"; //$NON-NLS-1$
static {
- String defaultType = System.getProperty(PROPERTY_DEFAULTTYPE);
- if (defaultType == null) {
- System.setProperty(PROPERTY_DEFAULTTYPE, "mozilla"); //$NON-NLS-1$
+ /* Under Linux instantiation of WebKit should be avoided,
+ * because WebKit and XULRunner running simultaneously
+ * may cause native errors.
+ *
+ * Also see JBIDE-9144 and JBIDE-10185. */
+ if (Platform.OS_LINUX.equals(Platform.getOS())) {
+ String defaultType = System.getProperty(PROPERTY_DEFAULTTYPE);
+ if (defaultType == null) {
+ System.setProperty(PROPERTY_DEFAULTTYPE, "mozilla"); //$NON-NLS-1$
+ }
}
}
}