Libraryless. Click here for Pure Java version (7641L/43K).
1 | svoid onTabSelected(JTabbedPane tabs, Runnable r) { |
2 | if (tabs != null) swing { |
3 | tabs.getModel().addChangeListener(changeListener(r)); |
4 | } |
5 | } |
6 | |
7 | svoid onTabSelected(JTabbedPane tabs, IVF1<Int> r) { |
8 | if (tabs != null && r != null) |
9 | onTabSelected(tabs, -> r.get(tabs.getSelectedIndex())); |
10 | } |
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1020865 |
Snippet name: | onTabSelected |
Eternal ID of this version: | #1020865/3 |
Text MD5: | bfea06fbf122f1f05c8b5af394a5b767 |
Transpilation MD5: | 6dc37781bcbe1823f28ed5291fa647c5 |
Author: | stefan |
Category: | javax / gui |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-04-03 18:02:24 |
Source code size: | 303 bytes / 10 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 352 / 451 |
Version history: | 2 change(s) |
Referenced in: | [show references] |