On Fri, 22 Aug 2025 07:38:43 GMT, Alessadro Parisi <d...@openjdk.org> wrote:
> > The documentation however seems quite clear that step 3 is also supposed to > > be done. > > So, as of now unmanaged parents do not layout their children? I thought they > did. @palexdev You are right, I missed something... thanks for taking an extensive look. My testing branch for this problem has a fix applied for [JDK-8360940](https://bugs.openjdk.org/browse/JDK-8360940), but it now looks like that fix is incomplete. What **should** happen when an unmanaged node is encountered is that changes in any of its children should not require re-layout of its parents (as an unmanaged node, all container parents ignore it and don't take it into account into their computations, so there is no point to re-layout the parents). However, due to a bug, code in `Node` will always walk up the layout tree to the scene root and will mark all ancestors as needing layout. The code that does this is not very subtle and if a layout is in progress it can sometimes cause the layout flags to go into a bad state (this is what [JDK-8360940](https://bugs.openjdk.org/browse/JDK-8360940) fixes). With that fix applied however, `Node` no longer always walks up the entire tree (and it shouldn't, as an unmanaged node is not affecting its parents). This however causes unmanaged parents to no longer be laid out at all, and this PR is supposed to fix that in turn. So, what it looks like is that this PR and the fix for [JDK-8360940](https://bugs.openjdk.org/browse/JDK-8360940) need to be a single PR. Sorry for the bad PR, I will move this to draft and provide a complete fix. ------------- PR Comment: https://git.openjdk.org/jfx/pull/1874#issuecomment-3214245362