I have recently started learning java and I am working/improving on a java IDE. I'm trying to find a way so that when you double click a file, the file is automatically opened with my program.
So far the only way I have found to do that is by using the apple extension com.apple.eawt (question found here). The only problem is that I have JDK 1.8 and this extension no longer works. Following this question, I looked for it on my computer and I believe it was last included in JDK 1.6.
My questions are: is there a way to use this extension in java 1.8? Or is there an Apple or non-Apple replacement that will do the same?
com.apple.eawt in the java.awt.Desktop classFor instance, you pointed to a question that recommended using Application.getApplication().setOpenFileHandler(myOpenHandeler).
This is equivalent to Desktop.setOpenFileHandler(OpenFilesHandler openFileHandler).
This functionality is also now available on platforms other than macOS, such as Windows.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With