From 2d20e469d41f4ad41ce63ee64f3dfda6dcc59b37 Mon Sep 17 00:00:00 2001 From: Grant Gayed Date: Tue, 25 Jan 2011 20:51:19 +0000 Subject: 335382 - WebKitGTK can now throw exception with SWT.WEBKIT style --- .../gtk/org/eclipse/swt/browser/BrowserFactory.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'bundles/org.eclipse.swt/Eclipse SWT Browser') diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/gtk/org/eclipse/swt/browser/BrowserFactory.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/gtk/org/eclipse/swt/browser/BrowserFactory.java index b97eeb6da9..ae86e384a1 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Browser/gtk/org/eclipse/swt/browser/BrowserFactory.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/gtk/org/eclipse/swt/browser/BrowserFactory.java @@ -15,9 +15,11 @@ import org.eclipse.swt.SWT; class BrowserFactory { WebBrowser createWebBrowser (int style) { - if ((style & SWT.MOZILLA) != 0 || (!WebKit.isInstalled () && (style & SWT.WEBKIT) == 0)) { + boolean webkitInstalled = WebKit.isInstalled (); + if ((style & SWT.MOZILLA) != 0 || (!webkitInstalled && (style & SWT.WEBKIT) == 0)) { return new Mozilla (); } + if (!webkitInstalled) return null; return new WebKit (); } -- cgit