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

20
LINES

< > BotCompany Repo | #1015970 // User's Primary E-Mail Address [Dyn Module, OK]

JavaX source code (Dynamic Module) [tags: use-pretranspiled] - run with: Stefan's OS

Uses 715K of libraries. Click here for Pure Java version (14710L/103K).

1  
!7
2  
3  
sclass UsersPrimaryMailAddress extends DynModule {
4  
  S address;
5  
6  
  JComponent visualize() {
7  
    ret jSection("Your Primary E-Mail Address",
8  
      centerAndSouth(centerBoldLabel(jLiveValueLabel(dm_fieldLiveValue(this, 'address))),
9  
      jcenteredbuttons("Change...", r {
10  
        final JTextField tf = jtextfield(address);
11  
        showFormTitled("Set your e-mail address",
12  
          "Address", tf, disableButtonWhileCalcing(func -> bool {
13  
            S s = getTextTrim(tf);
14  
            if (empty(s) || isValidEmailAddress(s))
15  
              ret true with setField(address := s);
16  
            ret false with infoBox(s + " is not a valid mail address");
17  
          }));
18  
      })));
19  
  }
20  
}

Author comment

Began life as a copy of #1015916

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: #1015970
Snippet name: User's Primary E-Mail Address [Dyn Module, OK]
Eternal ID of this version: #1015970/11
Text MD5: 4d5415c2daaa528214b31598773b0a36
Transpilation MD5: dc100445cc9d12f21bbfe64e3a1ed7ea
Author: stefan
Category: javax / stefan''s os
Type: JavaX source code (Dynamic Module)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-06-08 18:39:01
Source code size: 703 bytes / 20 lines
Pitched / IR pitched: No / No
Views / Downloads: 428 / 719
Version history: 10 change(s)
Referenced in: [show references]