1 | import java.beans.*; |
2 | |
3 | static NotTooOften fixSwingTitledBorderMemoryLeak_notTooOften = onlyEvery10Secs(); // just for printing |
4 | |
5 | svoid fixSwingTitledBorderMemoryLeak() {
|
6 | PropertyChangeListener[] l = UIManager.getPropertyChangeListeners(); |
7 | for (O o : l) |
8 | if (eq(className(o), "javax.swing.border.TitledBorder$1") |
9 | && getOpt(o, "this$0") != null) {
|
10 | setOpt(o, "this$0", null); |
11 | if (fixSwingTitledBorderMemoryLeak_notTooOften.yo()) |
12 | print("FIXED TitledBorder bug.");
|
13 | } |
14 | } |
Began life as a copy of #1016261
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1016262 |
| Snippet name: | fixSwingTitledBorderMemoryLeak |
| Eternal ID of this version: | #1016262/5 |
| Text MD5: | 64be15df52d611432fb995e116e7a59a |
| 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:36:30 |
| Source code size: | 511 bytes / 14 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 632 / 680 |
| Version history: | 4 change(s) |
| Referenced in: | [show references] |