You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jun 24, 2021. It is now read-only.
When an OpenJFX app uses Java 11 module system and UI is loaded from FXML that contains Images with URLs, it cannot be started. The reason is in this code in javafx/scene/image/Image.java:
if (!URL_QUICKMATCH.matcher(url).matches()) {
final ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader();
URL resource;
if (url.charAt(0) == '/') {
// FIXME: JIGSAW -- use Class.getResourceAsStream if resource is in a module
resource = contextClassLoader.getResource(url.substring(1));
} else {
// FIXME: JIGSAW -- use Class.getResourceAsStream if resource is in a module
resource = contextClassLoader.getResource(url);
}
if (resource == null) {
throw new IllegalArgumentException("Invalid URL or resource not found");
}
return resource.toString();
}
Fix this already! It has been ages since Java 9 is released, and you still have these FIXMEs ?
This is a major issue, you cannot start the app from the IDE, nor a user can start the app with standard Java 11 options for modular apps (--module-path and --module).
I even can fix it myself if you give me authorization to do so.