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

27
LINES

< > BotCompany Repo | #1015260 // preload

JavaX fragment (include)

1  
sbool preload_done;
2  
3  
static void preload(S vars, O sow, O reap) {
4  
  if (preload_done)
5  
    callF(reap);
6  
  else {
7  
    final new Flag goOn;
8  
    final Var<S> nextProgramID = new(programID());
9  
    showButtons("Go on", r {
10  
      hideControls(); // hide button again
11  
      goOn.raise();
12  
    }, "Go on as...", r {
13  
      selectSnippetID(voidfunc(S snippetID) {
14  
        hideControls();
15  
        nextProgramID.set(snippetID);
16  
        goOn.raise();
17  
      });
18  
    });
19  
    callF(sow);
20  
    print("Preload done");
21  
    goOn.waitUntilUp();
22  
    Class c = hotwireDependent(nextProgramID!);
23  
    setOpt(c, preload_done := true);
24  
    copyFields(mc(), c, splitAtSpace(vars));
25  
    callMain(c);
26  
  }
27  
}

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: #1015260
Snippet name: preload
Eternal ID of this version: #1015260/9
Text MD5: 709cfb75fc78dcfc672d188a21ca1aea
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-05-11 04:07:43
Source code size: 699 bytes / 27 lines
Pitched / IR pitched: No / No
Views / Downloads: 443 / 482
Version history: 8 change(s)
Referenced in: [show references]