Merge branch 'Djaler-patch-1'

This commit is contained in:
nathan 2018-01-11 16:09:55 +01:00
commit 61554d3f75

View File

@ -80,8 +80,14 @@ class Desktop {
} }
else if (java.awt.Desktop.isDesktopSupported() && java.awt.Desktop.getDesktop() else if (java.awt.Desktop.isDesktopSupported() && java.awt.Desktop.getDesktop()
.isSupported(java.awt.Desktop.Action.BROWSE)) { .isSupported(java.awt.Desktop.Action.BROWSE)) {
EventQueue.invokeLater(() -> {
try {
java.awt.Desktop.getDesktop() java.awt.Desktop.getDesktop()
.browse(uri); .browse(uri);
} catch (IOException | URISyntaxException e) {
throw new RuntimeException(e);
}
});
} }
else { else {
throw new IOException("Current OS and desktop configuration does not support browsing for a URL"); throw new IOException("Current OS and desktop configuration does not support browsing for a URL");