0

When I start this on my Windows laptop it goes well. But in MACOS it throws an NSException

void openInBrowserOnMouseClick(MouseEvent event) {
    if (!Desktop.isDesktopSupported() || !Desktop.getDesktop().isSupported(Desktop.Action.BROWSE)) {
        LOGGER.info("Action browsing is not supported on this platform");
        return;
    } else if (subject.getSite() == null) {
        showAlert(AlertType.WARNING, "Warning", "No site provided", "You should provide subject's site first");
        return;
    }
    try {
        Desktop.getDesktop().browse(new URI(subject.getSite()));
    } catch (IOException | URISyntaxException e) {
        LOGGER.error("Browsing error", e);
    }
}

NSException Stacktrace

0 Answers0