Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

9
LINES

< > BotCompany Repo | #1015850 // onDoubleClickThreaded (for JList/JTable/other components) - run actions in new thread

JavaX fragment (include)

1  
// runnable can be a func(O o) {} receving the selected item
2  
static JList onDoubleClickThreaded(final JList list, final O r) {
3  
  ret onDoubleClick(list, voidfunc(fS item) { thread-messagebox { callF(r, item); }});
4  
}
5  
6  
// runnable can be a func(O o) {} receving the selected row index
7  
static JTable onDoubleClickThreaded(final JTable table, final O r) {
8  
  ret onDoubleClick(table, voidfunc(final int row) { thread-messagebox { callF(r, row); }});
9  
}

Author comment

Began life as a copy of #1003586

download  show line numbers  debug dex  old transpilations   

Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1015850
Snippet name: onDoubleClickThreaded (for JList/JTable/other components) - run actions in new thread
Eternal ID of this version: #1015850/3
Text MD5: 3781f96e1b4c58f6f62a6a105b5b7e61
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-05-28 18:40:59
Source code size: 454 bytes / 9 lines
Pitched / IR pitched: No / No
Views / Downloads: 411 / 440
Version history: 2 change(s)
Referenced in: [show references]