From ee1c1b39b29fbad948068f93b2a0eeb537ef456c Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Wed, 31 Aug 2016 17:33:00 +0200 Subject: Update live timestamps to give a more live feeling --- core/js/js.js | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'core/js/js.js') diff --git a/core/js/js.js b/core/js/js.js index 799d2ba0b24..a123846a72e 100644 --- a/core/js/js.js +++ b/core/js/js.js @@ -1660,6 +1660,13 @@ function initCore() { $('body').delegate('#app-content', 'apprendered appresized', adjustControlsWidth); } + + // Update live timestamps every 30 seconds + setInterval(function() { + $('.live-relative-timestamp').each(function() { + $(this).text(OC.Util.relativeModifiedDate(parseInt($(this).attr('data-timestamp'), 10))); + }); + }, 30 * 1000); } $(document).ready(initCore); -- cgit v1.2.3