Libraryless. Click here for Pure Java version (5246L/29K).
static <A> void addOrRemoveComponent(bool add, Container a, Component b) { if (a == null || b == null) ret; if (add) swing { if (b.getParent() != a) addAndValidate(a, b); } else removeAndValidate(a, b); }
Began life as a copy of #1005926
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
Snippet ID: | #1034794 |
Snippet name: | addOrRemoveComponent - also validates |
Eternal ID of this version: | #1034794/4 |
Text MD5: | fdcc03263d912daefe3d1047d522b79e |
Transpilation MD5: | 3f7965e200ff554ad3effa2ad6129959 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-03-10 17:26:20 |
Source code size: | 231 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 163 / 251 |
Version history: | 3 change(s) |
Referenced in: | [show references] |