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

26
LINES

< > BotCompany Repo | #1027028 // Lock Screen

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

Uses 911K of libraries. Click here for Pure Java version (6740L/35K).

1  
!7
2  
3  
cmodule LockScreen > DynSingleFunction {
4  
  switchable bool withConfirm; // to filter out accidental clicks
5  
  transient JFrame frame;
6  
  
7  
  void doIt { showFullscreen(); }
8  
  
9  
  void showFullscreen enter {
10  
    if (frame != null) activateFrame(frame);
11  
    frame = showFullScreen(jfullcenter(
12  
      centerAndSouthWithMargins(
13  
        jcenteredlabel("Lock mode!"),
14  
        jMarginButton(20, "Exit", rThread exitStep2))));
15  
    onFrameClose(frame, r { frame = null; });
16  
  }
17  
  
18  
  void exitFullscreen enter {
19  
    disposeFrame(frame);
20  
  }
21  
  
22  
  void exitStep2 enter {
23  
    /*if (!withConfirm) TODO */
24  
    exitFullscreen();
25  
  }
26  
}

Author comment

Began life as a copy of #1027023

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

Snippet ID: #1027028
Snippet name: Lock Screen
Eternal ID of this version: #1027028/6
Text MD5: 3edf37b96178ae5654ad744ab880aa09
Transpilation MD5: 716450e663b9e716ef95da2c32f66d7e
Author: stefan
Category: javax / gui
Type: JavaX source code (Dynamic Module)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-02-11 14:32:17
Source code size: 644 bytes / 26 lines
Pitched / IR pitched: No / No
Views / Downloads: 283 / 455
Version history: 5 change(s)
Referenced in: [show references]