誰かがこれで私を助けることができるかどうか疑問に思います. Eclipse RAP アプリケーションで組み込みブラウザーを開こうとしています。私が見たすべての例は次のようになります。
link.addSelectionListener(new SelectionAdapter() {
@Override
public void widgetSelected(SelectionEvent event) {
try {
Browser b = new Browser(parent, SWT.NONE);
b.setText("<html><body>This is Unicode HTML content from memory</body></html>");
} catch (SWTError e) {
// Error handling here
}
}
});
しかし、それは(視覚的に)何もしません。Browser を ExternalBrowser に置き換えると、次のようになります。
link.addSelectionListener(new SelectionAdapter() {
@Override
public void widgetSelected(SelectionEvent event) {
try {
int browserStyle = ExternalBrowser.LOCATION_BAR;
ExternalBrowser.open( "myPage", "http://www.stackoverflow.com", browserStyle );
} catch (SWTError e) {
// Error handling here
}
}
});
できます。希望どおりではありませんが。
OS X 10.8.2 で Eclipse RCP 1.4.2 を使用しています。
どんな洞察も高く評価されます。