Diff

core/statsmanager.lua @ 6582:71b5de1d830b

statsmanager: Fire event at the start of collection to allow for polling
author Kim Alvefur <zash@zash.se>
date Tue, 10 Mar 2015 16:26:25 +0100
parent 6577:1e749832ed3b
child 6910:82765a4ec799
line wrap: on
line diff
--- a/core/statsmanager.lua	Tue Feb 24 15:22:09 2015 +0000
+++ b/core/statsmanager.lua	Tue Mar 10 16:26:25 2015 +0100
@@ -28,6 +28,7 @@
 
 	function collect()
 		local mark_collection_done = mark_collection_start();
+		fire_event("stats-update");
 		changed_stats, stats_extra = {}, {};
 		for stat_name, getter in pairs(stats.get_stats()) do
 			local type, value, extra = getter();