> This PR allows Main classes to be launched if they extend the Application 
> class, even when only having the JavaFX dependencies on the classpath instead 
> of the module path. This issue has been there for a long time and was quite 
> annoying for a lot of people: 
> https://stackoverflow.com/questions/78501081/how-do-i-fix-error-javafx-runtime-components-are-missing-and-are-required-to-r.
>  It is also a common use case for JavaFX developers when testing some PR to 
> create a quick reproducer class without setting up the module path properly.
> 
> While it is true that launching modern JavaFX via the classpath is 
> unuspported, it still launches and prints its own warnings, which is better 
> than the previous behavior. The old launcher error message in this case is 
> misleading as the runtime components aren't really missing, they are just not 
> in the module path.
> 
> This change should not have any change in behavior for any other case.
> 
> ---------
> - [x] I confirm that I make this contribution in accordance with the [OpenJDK 
> Interim AI Policy](https://openjdk.org/legal/ai).

Christopher Schnick has updated the pull request incrementally with one 
additional commit since the last revision:

  Revert optional check and move constant to proper scope

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/31016/files
  - new: https://git.openjdk.org/jdk/pull/31016/files/8a323ff2..97721625

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=31016&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=31016&range=00-01

  Stats: 11 lines in 1 file changed: 5 ins; 3 del; 3 mod
  Patch: https://git.openjdk.org/jdk/pull/31016.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/31016/head:pull/31016

PR: https://git.openjdk.org/jdk/pull/31016

Reply via email to