Libraryless. Click here for Pure Java version (5225L/29K).
svoid removeAndValidate(Component c) { if (c != null) swing { Container cc = c.getParent(); if (cc != null) { cc.remove(c); cc.revalidate(); cc.repaint(); // bugs without this } } } svoid removeAndValidate(Container container, Component c) { if (c != null) swing { if (c.getParent() == container) removeAndValidate(c); } }
Began life as a copy of #1010642
download show line numbers debug dex old transpilations
Travelled to 9 computer(s): bhatertpkbcr, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1019877 |
Snippet name: | removeAndValidate - remove form parent and validate parent |
Eternal ID of this version: | #1019877/4 |
Text MD5: | 6f82ffc5791e131f3970a1234dc16d9c |
Transpilation MD5: | ce50d408fafc5c997ebf14f355835f98 |
Author: | stefan |
Category: | javax / gui |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-03-10 17:25:23 |
Source code size: | 380 bytes / 16 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 300 / 385 |
Version history: | 3 change(s) |
Referenced in: | [show references] |