1 | static L<JComponent> paramsToButtons(O... params) {
|
2 | new L<JComponent> l; |
3 | for (int i = 0; i < l(params); i += 2) |
4 | if (params[i] != null) |
5 | if (params[i] instanceof JComponent) |
6 | l.add((JComponent) params[i--]); |
7 | else |
8 | l.add(jbutton((S) params[i], params[i+1])); |
9 | ret l; |
10 | } |
Began life as a copy of #1010175
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
| Snippet ID: | #1026644 |
| Snippet name: | paramsToButtons |
| Eternal ID of this version: | #1026644/1 |
| Text MD5: | dcaecbcf9c6e417b4de5e97a8f74d96f |
| Author: | stefan |
| Category: | javax / gui |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2020-01-18 15:36:47 |
| Source code size: | 309 bytes / 10 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 440 / 484 |
| Referenced in: | [show references] |