summaryrefslogtreecommitdiff
path: root/www/js/menu.js
diff options
context:
space:
mode:
authorAlex Xu <alex_y_xu@yahoo.ca>2014-02-08 08:47:33 -0500
committerAlex Xu <alex_y_xu@yahoo.ca>2014-02-08 08:47:33 -0500
commit47413d2a30f31d977529610f4ec8f5567d004fde (patch)
treee22a30434789335de89c4c417ae116dca654c151 /www/js/menu.js
parent856d6bb61e6c190a367aca0fcf6ac3438c71f079 (diff)
downloadhtml5ks-47413d2a30f31d977529610f4ec8f5567d004fde.tar.xz
html5ks-47413d2a30f31d977529610f4ec8f5567d004fde.zip
more stuff
Diffstat (limited to 'www/js/menu.js')
-rw-r--r--www/js/menu.js22
1 files changed, 14 insertions, 8 deletions
diff --git a/www/js/menu.js b/www/js/menu.js
index bcbb039..00d40b7 100644
--- a/www/js/menu.js
+++ b/www/js/menu.js
@@ -164,14 +164,20 @@
this.initOptions();
when.all([html5ks.fetch("json", "imachine"),
- html5ks.fetch("json", "script")]).then(function () {
- var start = this.elements.main.start;
- start.addEventListener("click", function () {
- this.elements.mainMenu.style.display = "none";
- html5ks.imachine.start().then(this.mainMenu.bind(this), console.error);
- }.bind(this), false);
- start.classList.remove("disabled");
- }.bind(this), console.error);
+ html5ks.fetch("json", "script").then(function (d) {
+ for (var k in d) {
+ if (k.slice(0, 3) === (html5ks.persistent.language === "en" ? "fr_" : "en_")) {
+ delete d[k];
+ }
+ }
+ }, console.error)]).then(function () {
+ var start = this.elements.main.start;
+ start.addEventListener("click", function () {
+ this.elements.mainMenu.style.display = "none";
+ html5ks.imachine.start().then(this.mainMenu.bind(this), console.error);
+ }.bind(this), false);
+ start.classList.remove("disabled");
+ }.bind(this), console.error);
},
_state: null,