summaryrefslogtreecommitdiff
path: root/www/js
diff options
context:
space:
mode:
authorAlex Xu <alex_y_xu@yahoo.ca>2013-09-07 21:21:14 -0400
committerAlex Xu <alex_y_xu@yahoo.ca>2013-09-07 21:21:14 -0400
commit86d70ba573286267f7f4fe22ffe1e392db58a0ea (patch)
tree992dc74b3998ca6265d878ce375c654674ea9c27 /www/js
parentbc17143e104dbcc0098cefecd75e11f63c7a1529 (diff)
downloadhtml5ks-86d70ba573286267f7f4fe22ffe1e392db58a0ea.tar.xz
html5ks-86d70ba573286267f7f4fe22ffe1e392db58a0ea.zip
fix minor bugs, add opus warn
Diffstat (limited to 'www/js')
-rw-r--r--www/js/api.js2
-rw-r--r--www/js/html5ks.js3
2 files changed, 4 insertions, 1 deletions
diff --git a/www/js/api.js b/www/js/api.js
index 4d746a5..869b1cf 100644
--- a/www/js/api.js
+++ b/www/js/api.js
@@ -55,7 +55,7 @@ window.html5ks.api = {
audio.src = src + ".opus";
} else if (Modernizr.audio.ogg) {
audio.src = src + ".ogg";
- } else if (Modernizr.audio.aac) {
+ } else if (Modernizr.audio.m4a) {
audio.src = src + ".m4a";
} else if (Modernizr.audio.wav) {
audio.src = src + ".wav";
diff --git a/www/js/html5ks.js b/www/js/html5ks.js
index 502ca75..9ca2bde 100644
--- a/www/js/html5ks.js
+++ b/www/js/html5ks.js
@@ -192,6 +192,9 @@ window.html5ks = {
if (/MSIE/.test(navigator.userAgent)) {
document.getElementById("ie").style.display = "block";
}
+ if (!Modernizr.audio.opus) {
+ document.getElementById("opus").style.display = "block";
+ }
for (var i = 0; i < warns.length; i++) {
if (window.getComputedStyle(warns[i]).getPropertyValue("display") !== "none") {
warn.style.visibility = "visible";