On Wed, 23 Sep 2026 15:47:49 GMT, Marius Hanl <[email protected]> wrote:
>> This PR integrates the `Platform` functionality into `PlatformUtil`, so that >> we only have one place where we do OS stuff. And can delete `Platform`. >> >> Something that was first discussed in >> https://github.com/openjdk/jfx/pull/1864 and I also saw when I did the >> cleanup some months ago in PR https://github.com/openjdk/jfx/pull/2190. >> >> --------- >> - [x] I confirm that I make this contribution in accordance with the >> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai). > > Marius Hanl has updated the pull request incrementally with one additional > commit since the last revision: > > proper getter now modules/javafx.graphics/src/main/java/com/sun/glass/ui/GlassPlatform.java line 51: > 49: // PlatformUtil must be initialized first (in getPlatform()), as > it may set the system properties read below. > 50: String platform = getPlatform(); > 51: PLATFORM_FACTORY = "com.sun.glass.ui." + > platform.toLowerCase(Locale.ROOT) + "." + platform + "PlatformFactory"; Another idea I imlemented: Instead of return the platform, we could return the Platform factory from `GlassPlatform`. That seems like a good location and we do not ne to expose `Platform.determinePlatform()` (like before). ------------- PR Review Comment: https://git.openjdk.org/jfx/pull/2299#discussion_r4084384285
