From 68fe2b01744723b02b4acc0818936249f2940975 Mon Sep 17 00:00:00 2001 From: Simon Grim Date: Wed, 9 Mar 2016 01:23:39 +0500 Subject: [PATCH] add workaround to be able to play sound notifications on Firefox --- js/interface_common.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/js/interface_common.js b/js/interface_common.js index aed0539..5ad554e 100644 --- a/js/interface_common.js +++ b/js/interface_common.js @@ -2333,4 +2333,11 @@ $(document).ready(function () { } changeStyle(); + + // need to play something once in result of click on Firefox to be able to play sound notifications + // FXIME it's just workaround of FF's bug, see https://bugzilla.mozilla.org/show_bug.cgi?id=1197631 + $('body').on('click', function () { + playSound('player', $.Options.sndMention.val, 0.001); + setTimeout(function () {$('body').off('click');}, 10000); // sound must be played before unbinding + }); });