From 237359d107c5f8fb3e1f7a3532696eb19a6c56fc Mon Sep 17 00:00:00 2001 From: David Vazgenovich Shakaryan Date: Mon, 2 May 2022 15:20:34 -0700 Subject: web: buffer player info and flush on state change Constant calls from Wasm to JS to replace unchanged elements in the DOM is not very efficient. --- web/web_ui.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'web/web_ui.h') diff --git a/web/web_ui.h b/web/web_ui.h index fa961fb..a302e0a 100644 --- a/web/web_ui.h +++ b/web/web_ui.h @@ -3,6 +3,12 @@ #include +void ui_flush(); + +void ui_flush_player_info(int pn); +void ui_set_player_avg(int pn, double avg); + +void update_player_name(int pn, char *str); void update_player_sugg(int pn, int rem); void update_player_avg(int pn, int n_darts); void update_player_rem(int pn, int rem); -- cgit v1.2.3-70-g09d2