aboutsummaryrefslogtreecommitdiffstats
path: root/src/vega.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/vega.h')
-rw-r--r--src/vega.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/vega.h b/src/vega.h
index 47e7e91..f01667b 100644
--- a/src/vega.h
+++ b/src/vega.h
@@ -36,6 +36,16 @@ typedef struct {
} VegaScreen;
void vega_screen(VegaScreen *, const PureModule *);
+
+/* The wall-clock time events see on a live surface: milliseconds since 1970
+ * (UTC). Scripts set their own (time MS). */
+double vega_now(void);
+/* When each timer input ticks next. run ticks every one due at now (a tick
+ * sees now) and gives the milliseconds until the next, or -1 without timers;
+ * ticked says whether any did. Missed ticks are not made up. */
+typedef struct { double next[PURE_MODULE_INPUTS]; } VegaTimers;
+void vega_timers_start(VegaTimers *, const PureModule *, double now);
+long vega_timers_run(VegaTimers *, PureApp *, double now, bool *ticked);
/* What a module seems to mean but does not meet: a list label that is not
* text, a _focus view without its table, a column a list never shows, a
* second text input. Each finding names the view or input it is about;