Desktop.browse(...) freezes JFX on Linux with GNOME
See original GitHub issueDescribe the bug
Any call to
Desktop.browse(...)
freezes Recaf on Linux machines with GNOME
To Reproduce
- Say “yes” to opening the documentation
- Help > System info > open recaf directory
The Solution
From: https://stackoverflow.com/questions/23176624/javafx-freeze-on-desktop-openfile-desktop-browseuri
if( Desktop.isDesktopSupported() )
{
new Thread(() -> {
try {
Desktop.getDesktop().browse( new URI( "http://..." ) );
} catch (IOException | URISyntaxException e1) {
e1.printStackTrace();
}
}).start();
}
Ideally since this would be all in the UI
module, we could use our existing Threads
class for pooling the threads.
We should make a wrapper utility so that we don’t have this big block of code every time we want to invoke browse
. This should be done on both master
and dev3
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
JavaFX Freeze on Desktop.open(file), Desktop.browse(uri)
I'm running some code in Java on Ubuntu 12.04 LTS 64 Bit (with Gnome Shell), using Oracle ...
Read more >JavaFX Freeze on Desktop.open(file), Desktop.browse(uri)
I'm running some code in Java on Ubuntu 12.04 LTS 64 Bit (with Gnome Shell), using Oracle JDK 1.8.0_05 via NetBeans8.0.
Read more >How to fix a frozen Gnome desktop session - AddictiveTips
To restart the Gnome Shell session while everything is frozen, start by pressing Alt + F2 on the keyboard. Executing this keyboard combo...
Read more >Using the Desktop.open() method from a JavaFX application ...
pdf file works in a Java application, but in a JavaFX application it hangs the application and does not open. This happens on...
Read more >253594 – Stopping on a breakpoint in JavaFX event handler ...
Add breakpoint to any event handler and my entire desktop freezes, ... Running on Fedora 22 with Gnome 3.16 and stock fedora kernel, ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ported to 3x: 88adb702043beac1d9738b1afbb33794e3d1d3e6
Fixed in 2x as of https://github.com/Col-E/Recaf/commit/3212458c61295834f0bf851cf1efea46dd2e4793, still needs to be ported to 3x though