Using WebKit for SWT Browser inside Eclipse plugin

让人想犯罪 __ 提交于 2020-01-13 20:39:13

问题


I tried today to use the WebKit as the Browser's underlying renderer for my eclipse plugin but no luck.

I followed the recommended instructions and my current environment is as follows:

  • OS: Windows 7 (x64)
  • Safari installed (in the PATH too)
  • 32 bit SWT (eclipse RCP indigo SR1 32)

added the following line to eclipse.ini

-Dorg.eclipse.swt.browser.DefaultType=webkit

Now when I try to instantiate the browser:

Browser b = new Browser(parent, SWT.WEBKIT);
b.setUrl("http://whatismybrowser.com");

I get the following error:

Failed to load the swt-webkit library

Any suggestions?

Thanks.


回答1:


I got this problem too What you need to do use JVM : 32bit SWT :32 bit

set the safari.exe path in your environment settings , (If you are using older version of Windows)

Else if SWT and JVM are not of same 32 bit it will generate error .



来源:https://stackoverflow.com/questions/9117651/using-webkit-for-swt-browser-inside-eclipse-plugin

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!