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

5
LINES

< > BotCompany Repo | #1019409 // focusedTextFieldAndButton (focus on first show)

JavaX fragment (include)

static JPanel focusedTextFieldAndButton(S defaultText, S buttonText, VF1<S> onEnter) {
  final JTextField tf = jtextfield(defaultText);
  onFirstComponentShow(tf, r { focus(tf) });
  ret textFieldAndButton(tf, buttonText, onEnter);
}

Author comment

Began life as a copy of #1019371

download  show line numbers  debug dex  old transpilations   

Travelled to 12 computer(s): bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1019409
Snippet name: focusedTextFieldAndButton (focus on first show)
Eternal ID of this version: #1019409/1
Text MD5: 7a3065530265b2bd2c7cfce09b81df72
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-11-05 01:04:19
Source code size: 237 bytes / 5 lines
Pitched / IR pitched: No / No
Views / Downloads: 305 / 330
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)