This commit is contained in:
Alexander Yakovlev 2017-08-01 18:03:31 +07:00
parent 15693c79ae
commit 1b9bddcd8b
1 changed files with 2 additions and 3 deletions

View File

@ -27,6 +27,8 @@ $.getJSON('game/translations/'+i18n.lang+'.json', (data) ->
switchTab = (tabid) ->
$(".tab").removeClass("active")
$("#"+tabid).addClass("active")
if tabid == "storytab" and not salet.here().canSave
salet.goBack()
$(document).ready(() ->
window.addEventListener('popstate', (event) ->
@ -44,9 +46,6 @@ $(document).ready(() ->
)
$("body").on("click", ".tab", (event) ->
switchTab(event.target.id)
if (event.target.id == "storytab")
if not salet.here().canSave
salet.goBack()
return true
)
$("#page").on("click", "a", (event) ->