webviewjar icon indicating copy to clipboard operation
webviewjar copied to clipboard

Doesnt Work on Mac OS Big Sur

Open gochev opened this issue 4 years ago • 1 comments

Does Not run in JDK 8 and 11 on Mac OS Big Sur using AdoptOpenJDKs

 java -jar WebView.jar http://google.com  ✔  ⚙

Attaching the output and the log

consoleout.txt

Attaching hs_err_pid72130.log hs_err_pid72130.log

gochev avatar Nov 25 '20 16:11 gochev

FWIW, I was able to get it run on Big Sur and JDK 16 with this:

        WebView webview = new WebView()
                .size(800, 600)
                .title("Test")
                .resizable(true)
                .url("https://theoryofgeek.com/")
                .addJavascriptCallback("callback", x ->
                {
                    System.out.println(x);
                });
        webview.show();

and also using the -XstartOnFirstThread JVM option.

Running without the -XstartOnFirstThread JVM option results in this stack:

*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'NSWindow drag regions should only be invalidated on the Main Thread!'

wiverson avatar Apr 22 '21 22:04 wiverson