On Thu, 22 Jul 2021 11:50:11 GMT, Florian Kirmaier <fkirma...@openjdk.org> 
wrote:

>> After thinking about this issue for some time, I've now got a solution.
>> I know put the scene in the state it is, before is was shown, when the 
>> dirtyNodes are unset, the whole scene is basically considered dirty. 
>> This has the drawback of rerendering, whenever a window is "reshown", but it 
>> restores sanity about memory behaviour, which should be considered more 
>> important.
>
> Florian Kirmaier has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   JDK-8269907
>   The bug is now fixed in a new way. Toolkit now supports registering 
> CleanupListeners, which can clean up the dirty nodes, avoiding memoryleaks.

It would be possible to add it to the existing PulseListener, but i think it 
would be more complicated. It might require some code to decide whether it 
should only clean the dirty children, or do the full pulse. The logic to 
add/remove the listener also would have to be more complicated.

Actually it was my first approach, but i didn't find a good place "to get 
started".

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

PR: https://git.openjdk.java.net/jfx/pull/584

Reply via email to