This repository has been archived by the owner on Jun 24, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 146
Use freedesktop's xdg-open to get default web browser on Linux systems #260
Labels
enhancement
New feature or request
Comments
Tristan971
changed the title
Use freedesktop's
Use freedesktop's xdg-open to get default web browser on Linux systems
Oct 30, 2018
xdg-open
to get default web browser on Linux systems
This seems like a reasonable idea. If you are interested in contributing a fix for this change, please read CONTRIBUTING.md. Two recommendations:
|
Alright, will go through with the oracle agreement then the linux version 👍 Thanks for the reply! |
(by the way this is not abandoned, it's just the OCA being quite the hurdle to get done) |
OK |
In the mean time, can you file an enhancement request at https://bugreport.java.com/ ? |
Tracked in JBS as: JDK-8214069. |
I see that your OCA has been processed. |
This was referenced Nov 21, 2018
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hello, I am pretty sure this has been reported already (at the very least, probably even discussed) but I just cannot find it, please do not hesitate to let me know if you have the original handy.
On Linux systems, right now (i.e. in OpenJFX 11) getting a handle on the default browser is done through a static array in
HostServicesDelegate
as so :which is then iterated over to find the installed one and run a process to open it :
This :
firefox-beta
at least on Archlinux derivates)In regard to these issues, a simple fix would be to rely on the widely accepted default of relying on freedesktop's
xdg-open
command which will automatically select any OS-registered browser in most GUI-enabled Linux environments (while JavaFX has some headless support I find it more reasonable to assume users generally have a GUI given the very nature of JavaFX).I propose a fix that would remove the array and its subsequent usage to be replaced by
xdg-open
.In the very same vein, I would assume that this issue (or another one at least) should use Apple's
open
command for macOS rather than relying on AWT'sDesktop
class.Thank you for your consideration and sorry if this has been debated but again I could not easily find a place where such a debate would have been had (at least not in a reasonable search time).
--- (If not clear I would of course volunteer for implementing that/these fixes)
The text was updated successfully, but these errors were encountered: