diff --git a/templates/bootstrap/dashboard/blocks/default.tpl b/templates/bootstrap/dashboard/blocks/default.tpl index 85201d0c..376e9d08 100644 --- a/templates/bootstrap/dashboard/blocks/default.tpl +++ b/templates/bootstrap/dashboard/blocks/default.tpl @@ -38,8 +38,8 @@ -{/if} +{/if} \ No newline at end of file diff --git a/templates/bootstrap/dashboard/default.tpl b/templates/bootstrap/dashboard/default.tpl index dbb3b8aa..e042fa1e 100644 --- a/templates/bootstrap/dashboard/default.tpl +++ b/templates/bootstrap/dashboard/default.tpl @@ -1,19 +1,6 @@ {if $smarty.session.AUTHENTICATED|default} -
diff --git a/templates/bootstrap/dashboard/js/api.tpl b/templates/bootstrap/dashboard/js/api.tpl index f81a1fe0..f2c2b7f3 100644 --- a/templates/bootstrap/dashboard/js/api.tpl +++ b/templates/bootstrap/dashboard/js/api.tpl @@ -5,6 +5,7 @@ $(document).ready(function(){ var audioPath = "{/literal}{$PATH}{literal}/audio/"; var manifest = [ {id:"ding", src:"ding.ogg"} ]; + var muteFlag = 1; createjs.Sound.alternateExtensionseExtensions = ["mp3"]; createjs.Sound.registerManifest(manifest, audioPath); @@ -250,6 +251,23 @@ $(document).ready(function(){ } }); })(); + + // Mute Button + $('#muteButton').click(function(){ + if(muteFlag == 2) { + muteFlag = 1; + createjs.Sound.setMute(false); + $(this).toggleClass("btn-xs btn-danger").toggleClass("btn-xs btn-success"); + //$(this).find($(".fa")).removeClass('fa-volume-off').addClass('fa-volume-up'); + } else { + muteFlag = 2; + createjs.Sound.setMute(true); + $(this).toggleClass("btn-xs btn-success").toggleClass("btn-xs btn-danger"); + //$(this).find($(".fa")).removeClass('fa-volume-up').addClass('fa-volume-off'); + } + }); + + }); {/literal}