Uses 1059K of libraries. Click here for Pure Java version (6724L/33K).
1 | !7 |
2 | |
3 | cmodule2 AutoReloadButtons > DynPrintLogAndEnabled { |
4 | switchable int delay = 5; // seconds |
5 | |
6 | start { |
7 | dm_onSnippetTranspiled(voidfunc(S snippetID) { |
8 | if (!enabled) ret; |
9 | if (empty(dm_modulesWithSnippetID(snippetID))) ret; |
10 | |
11 | dm_action("Reloading module " + snippetID + " in " + delay + "...", r { |
12 | sleepSeconds(delay); |
13 | dm_reloadAllModulesWithSnippetID(snippetID); |
14 | }); |
15 | }); |
16 | } |
17 | |
18 | bool warnOnDelete() { true; } |
19 | } |
Began life as a copy of #1021905
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1030826 |
Snippet name: | Auto-Update Modules With Delay |
Eternal ID of this version: | #1030826/6 |
Text MD5: | 9b1afe6834b771ad7a906984310f248b |
Transpilation MD5: | a6d6e2186da7568911864efbb24935a0 |
Author: | stefan |
Category: | javax |
Type: | JavaX source code (Dynamic Module) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-03-31 16:15:41 |
Source code size: | 486 bytes / 19 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 148 / 3665 |
Version history: | 5 change(s) |
Referenced in: | [show references] |