From 1a69ddd7562f54f6624f38d3207a2dcb96a4450f Mon Sep 17 00:00:00 2001 From: Grant Gayed Date: Fri, 16 Nov 2012 16:13:17 -0500 Subject: Bug 394473 - Mozilla Browser.evaluate broken for XULRunner 3.x due to changes to support XULRunner >= 4 --- .../common/org/eclipse/swt/browser/Mozilla.java | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java index 13f30040bf..40f2af1945 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java @@ -706,6 +706,9 @@ public void create (Composite parent, int style) { LocationProvider = new AppFileLocProvider (MozillaPath, profilePath, cacheParentPath, IsXULRunner); LocationProvider.AddRef (); + /* write external.xpt to the file system if needed */ + initExternal (LocationProvider.profilePath); + /* invoke appropriate Init function (based on mozilla version) */ initXPCOM (MozillaPath, IsXULRunner); } @@ -905,9 +908,6 @@ public void create (Composite parent, int style) { interfaceRequestor.Release (); componentRegistrar.Release (); - /* write external.xpt to the file system if needed */ - initExternal (LocationProvider.profilePath); - if (!factoriesRegistered) { HelperAppLauncherDialogFactory dialogFactory = new HelperAppLauncherDialogFactory (); dialogFactory.AddRef (); @@ -1761,13 +1761,6 @@ static String InitDiscoverXULRunner () { } void initExternal (String profilePath) { - /* - * external.xpt does not need to be written to the file system if the - * XULRunner version is >= 4 since External.java handles this case - * differently than for earlier XULRunner releases. - */ - if (!IsPre_4) return; - File componentsDir = new File (profilePath, AppFileLocProvider.COMPONENTS_DIR); java.io.InputStream is = Library.class.getResourceAsStream ("/external.xpt"); //$NON-NLS-1$ if (is != null) { -- cgit