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

36
LINES

< > BotCompany Repo | #1016556 // Latest Changed Snippets [Dyn Module]

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

Libraryless. Click here for Pure Java version (15507L/110K).

!7

sclass LatestChangedSnippets extends DynTable {
  L<Map> data;
  
  JComponent visualize() {
    JComponent c = super.visualize();
    ret withCenteredButtons(c,
      tableDependentButton_extraCondition(table, "Add Module", r {
        S id = strOrNull(selectedTableCell(table, "ID"));
        if (isSnippetID(id) && cic((S) selectedTableCell(table, "Type"), "(Dynamic Module)"))
          dm_addDynamicModuleDialog2(id);
      }, func -> bool {
        cic((S) selectedTableCell(table, "Type"), "(Dynamic Module)")
      }));
  }

  void start {
    ownTimer(doEvery(60.0, r actualUpdate));
  }
  
  void actualUpdate { temp enter(); actualCalc(); }
  
  L<Map> calc() {
    ret data != null ? data : actualCalc();
  }
  
  L<Map> actualCalc() ctex {
    time "Get Latest Snippets" {
      L<Snippet> l = recentlyChangedSnippets();
    }
    ret setFieldAndReturn(data := map(l, func(Snippet s) -> Map {
      humanizeKeys(putKeysFirst(objectAsMap(s), "title", "id"))
    }));
  }
}

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1016556
Snippet name: Latest Changed Snippets [Dyn Module]
Eternal ID of this version: #1016556/11
Text MD5: 6f60bc153f42f7fc23dcc74fcc653a37
Transpilation MD5: 8dddd6db3c2e69ba2a631103013f69bb
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-11-24 04:13:08
Source code size: 1023 bytes / 36 lines
Pitched / IR pitched: No / No
Views / Downloads: 437 / 21366
Version history: 10 change(s)
Referenced in: [show references]