On Thu, 12 Jun 2025 21:05:38 GMT, Markus Mack <mm...@openjdk.org> wrote:

>> Michael Strauß has updated the pull request with a new target base due to a 
>> merge or a rebase. The pull request now contains 108 commits:
>> 
>>  - Fix full-screen bug
>>  - Merge branch 'master' into feature/extended-window
>>  - only dispose ViewSceneOverlay when non-null
>>  - Rename default window button style classes
>>  - Set the scene root as the parent of the overlay node
>>  - rename WindowManager to DesktopEnvironment
>>  - enable preview feature system properties for tests
>>  - javadoc fix
>>  - fix memory leak in ViewScene
>>  - Merge branch 'master' into feature/extended-window
>>  - ... and 98 more: https://git.openjdk.org/jfx/compare/72c1c21a...3fdc465f
>
> modules/javafx.graphics/src/main/java/javafx/scene/Parent.java line 1935:
> 
>> 1933:         // the scene graph. When this method is called on the root 
>> node, we need to check whether the supposed
>> 1934:         // child is actually contained in the children list.
>> 1935:         if (!childSet.contains(node)) {
> 
> My tests confirm that the issue occurs when `setChildDirty` is called on the 
> overlay node. This method may also be called from `childIncluded`and 
> `childExcluded` which seems to be triggered when a node's visibility changes. 
> If this doesn't happen the fix looks fine. Alternative may be to move the 
> check inside `setChildDirty`.

I added the same check in `Parent.childVisibilityChanged(Node)`. These two 
methods seem to be the only methods that are called by children on their 
parents in this particular way, passing themselves as an argument.

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

PR Review Comment: https://git.openjdk.org/jfx/pull/1605#discussion_r2143718769

Reply via email to