1 | import java.beans.*; |
2 | |
3 | please include function fixSwingTitledBorderMemoryLeak. |
4 | |
5 | svoid unfixSwingTitledBorderMemoryLeak() { |
6 | PropertyChangeListener[] l = UIManager.getPropertyChangeListeners(); |
7 | for (O o : l) |
8 | if (eq(className(o), "javax.swing.border.TitledBorder$1") && getOpt(o, "this$0") == null) { |
9 | O value = getWeakRef((WeakReference) getOpt(o, "val$weakReference")); |
10 | if (value != null) { |
11 | setOpt(o, "this$0", value); |
12 | if (fixSwingTitledBorderMemoryLeak_notTooOften.yo()) |
13 | print("UNFIXED TitledBorder bug."); |
14 | } |
15 | } |
16 | } |
Began life as a copy of #1016262
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1018601 |
Snippet name: | unfixSwingTitledBorderMemoryLeak - to allow changing L&F [seems to work] |
Eternal ID of this version: | #1018601/4 |
Text MD5: | 5c679c88c0e21ac7533029086fc8e9b3 |
Author: | stefan |
Category: | javax / modules |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-10-16 13:38:30 |
Source code size: | 581 bytes / 16 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 340 / 398 |
Version history: | 3 change(s) |
Referenced in: | [show references] |