RFR: 8354943: [Linux] Simplify and update glass gtk backend: window sizing, positioning, and state management issues [v9]

Thiago Milczarek Sayao tsayao at openjdk.org
Thu May 1 13:23:46 UTC 2025


On Tue, 29 Apr 2025 18:46:39 GMT, Martin Fox <mfox at openjdk.org> wrote:

>> Thiago Milczarek Sayao has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Remove old comment
>
> tests/system/src/test/java/test/robot/javafx/stage/StageAttributesTest.java line 312:
> 
>> 310:     @ParameterizedTest(name = PARAMETERIZED_TEST_DISPLAY)
>> 311:     @EnumSource(names = {"DECORATED", "UNDECORATED"})
>> 312:     void testStageStatePrecedenceOrderIconifiedMaximizedBeforeShow(StageStyle stageStyle) throws InterruptedException {
> 
> The precedence rules written into the spec are very problematic and it would be a bear to implement them. For example, if you attempt to maximize an iconified stage on Windows it will de-iconify. Making it stay iconified and maximize later would take real effort. Maximizing an iconified stage on Mac does nothing (glass loses the maximized state) and fixing that would also take a lot of work. I really think our time would be better spent leaving things as-is and updating the spec.
> 
> I don't think the API calls for maximizing and iconifying the stage are useful to begin with. These are features provided to users so they can manager their desktop real estate. There's not a lot of compelling use cases for apps to do this.

I agree we should do an update on the documentation and accept that platforms differ on some aspects (that are acceptable) such as this one.

Maximize maybe there's the case to start maximized to cover the screen for single-application use machines (common in enterprise software). I don't see the use for iconify.

I have removed this test and the related ones that test state precedence order.

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

PR Review Comment: https://git.openjdk.org/jfx/pull/1789#discussion_r2070259389


More information about the openjfx-dev mailing list