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

16
LINES

< > BotCompany Repo | #1006756 // setText_noWait - more flexible shorthand for JTextComponent/JLabel/JButton.setText() - uses AWT thread

JavaX fragment (include)

svoid setText_noWait(JTextComponent c, O text) {
  setText_noWait((O) c, text);
}

svoid setText_noWait(JLabel c, O text) {
  setText_noWait((O) c, text);
}

svoid setText_noWait(JButton c, O text) {
  setText_noWait((O) c, text);
}

svoid setText_noWait(fO c, O text) {
  final S s = str(text);
  awtIfNecessary { call(c, "setText", s); }
}

Author comment

Began life as a copy of #1003310

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: #1006756
Snippet name: setText_noWait - more flexible shorthand for JTextComponent/JLabel/JButton.setText() - uses AWT thread
Eternal ID of this version: #1006756/1
Text MD5: 3aa35c0824a4514f954bcf87527a8bed
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-02-03 18:42:24
Source code size: 356 bytes / 16 lines
Pitched / IR pitched: No / No
Views / Downloads: 433 / 466
Referenced in: [show references]