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

24
LINES

< > BotCompany Repo | #1026339 // DynCopiedObjectTable

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (18634L/133K).

1  
abstract sclass DynCopiedObjectTable<A> extends DynObjectTable<A> {
2  
  S srcModuleLibID;
3  
  transient bool autoScrollDown;
4  
  transient ReliableSingleThread rstGrabData = dm_rst(this, r grabData);
5  
  
6  
  void init {} // override this in subclasses
7  
8  
  start {
9  
    init();
10  
    dm_require(srcModuleLibID);
11  
    dm_vmBus_onMessage listChanged(voidfunc(O mod, L list) {
12  
      if (empty(srcModuleLibID) || dm_isMe(mod) || !eq(dm_moduleLibID(mod), srcModuleLibID)) ret;
13  
      rstGrabData.trigger(); // goes through RST + Q
14  
    });
15  
    rstGrabData.trigger();
16  
  }
17  
  
18  
  void grabData {
19  
    L l = cast dm_callModuleWithLibID(srcModuleLibID, 'getList);
20  
    if (l == null) ret;
21  
    setList(quickImport(l));
22  
    if (autoScrollDown) scrollDown();
23  
  }
24  
}

Author comment

Began life as a copy of #1026333

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: #1026339
Snippet name: DynCopiedObjectTable
Eternal ID of this version: #1026339/4
Text MD5: c2ed848a686a780a488e7037c1b83243
Transpilation MD5: b68f52ba996f5a7edbf64cafbf14ecc1
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-12-24 16:42:50
Source code size: 754 bytes / 24 lines
Pitched / IR pitched: No / No
Views / Downloads: 171 / 507
Version history: 3 change(s)
Referenced in: [show references]