diff options
author | piernov <piernov@piernov.org> | 2016-05-03 10:37:18 +0200 |
---|---|---|
committer | piernov <piernov@piernov.org> | 2016-05-03 10:37:18 +0200 |
commit | 64e184b901fd4e7c9a829d14c5c34416923171c3 (patch) | |
tree | 70b5281ca85a38ef2a077e226dcce56a40ed563a /js/gui.js | |
parent | add9d3248a5adc02b071a301005c6f11195f7f7b (diff) | |
parent | b8112f72b322fe5bf7048ac76251c8c637b9fee2 (diff) | |
download | candybox-64e184b901fd4e7c9a829d14c5c34416923171c3.tar.gz candybox-64e184b901fd4e7c9a829d14c5c34416923171c3.tar.bz2 candybox-64e184b901fd4e7c9a829d14c5c34416923171c3.tar.xz candybox-64e184b901fd4e7c9a829d14c5c34416923171c3.zip |
Merge branch 'master' into alexichi
Diffstat (limited to 'js/gui.js')
-rw-r--r-- | js/gui.js | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -6,10 +6,8 @@ function changeTab() { var id = window.location.hash.substr(4); var tabs = document.querySelectorAll("#tabs-panel > ul > li"); for(var i=0; i < tabs.length; i++) { - if(i == id-1) - tabs[i].className = "active"; - else - tabs[i].className = ""; + if(i == id-1) tabs[i].classList.add("active"); // Doesn't work with IE < 10 (and Opera Mini), but who cares? + else tabs[i].classList.remove("active"); } } |