Add the short score to the document title.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Wed, 12 Nov 2014 19:19:38 +0000 (20:19 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Wed, 12 Nov 2014 19:19:38 +0000 (20:19 +0100)
www/js/remoteglot.js

index c183493..9d83e55 100644 (file)
@@ -600,6 +600,10 @@ var update_board = function(data, num_viewers) {
        // The score.
        if (data['score'] !== null) {
                $("#score").text(data['score']);
+               var short_score = data['score'].replace(/Score: */, "");
+               document.title = '(' + short_score + ') analysis.sesse.net';
+       } else {
+               document.title = 'analysis.sesse.net';
        }
 
        // The search stats.