RFR: 8295506: ButtonBarSkin: memory leak when changing skin [v2]
Ajit Ghaisas
aghaisas at openjdk.org
Thu Dec 1 11:13:53 UTC 2022
On Wed, 30 Nov 2022 17:10:50 GMT, Andy Goryachev <angorya at openjdk.org> wrote:
>> as determined by SkinMemoryLeakTest (remove line 165) and a leak tester
>> https://github.com/andy-goryachev-oracle/Test/blob/main/src/goryachev/apps/LeakTest.java
>>
>> Make sure to configure the current test in LeakTest:
>> protected final Type WE_ARE_TESTING = Type.BUTTON_BAR;
>>
>>
>> caused by:
>> - adding and not removing listeners
>> - adding and not removing children Nodes
>
> Andy Goryachev has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 23 commits:
>
> - Merge remote-tracking branch 'origin/master' into
> 8295506.button.bar.skin
> - Merge remote-tracking branch 'origin/master' into
> 8295506.button.bar.skin
> - Merge branch '8294809.listener.helper' into 8295506.button.bar.skin
> - 8294809: generics
> - Merge branch '8294809.listener.helper' into 8295506.button.bar.skin
> - 8294809: is alive
> - Revert "8294809: removed weak listeners support"
>
> This reverts commit 2df4a85db638d76cacaf6c54ba669cdb3dd91a18.
> - 8295506: button bar skin
> - 8294809: removed weak listeners support
> - 8294809: use weak reference correctly this time
> - ... and 13 more: https://git.openjdk.org/jfx/compare/0a785ae0...759ecaf4
modules/javafx.controls/src/main/java/javafx/scene/control/skin/ButtonBarSkin.java line 139:
> 137: }
> 138:
> 139: updateButtonListeners(getSkinnable().getButtons(), false);
Can we use `ListenerHelper` in `updateButtonListeners` method?
We may need to use `ListernerHelper` of `ButtonSkin`.
-------------
PR: https://git.openjdk.org/jfx/pull/921
More information about the openjfx-dev
mailing list