Forgot to refresh scrolling element..

This commit is contained in:
Kasper Rynning-Tønnesen
2015-04-17 13:55:15 +02:00
parent 7001167ff9
commit fbfddb7bd2
2 changed files with 10 additions and 2 deletions

View File

@@ -46,6 +46,9 @@ socket.on("pw", function(msg)
$("input[name="+names[i]+"]").attr("disabled", false); $("input[name="+names[i]+"]").attr("disabled", false);
} }
$(".card-action").removeClass("hide"); $(".card-action").removeClass("hide");
refresh_scroll();
localStorage.setItem("passord_i_klartekst_lol", msg); localStorage.setItem("passord_i_klartekst_lol", msg);
Materialize.toast("Correct Password. You are now admin", 4000); Materialize.toast("Correct Password. You are now admin", 4000);
}); });

View File

@@ -95,8 +95,7 @@ function populate_list(msg, conf_only)
myScroll.maxScrollY = myScroll.maxScrollY - 5; myScroll.maxScrollY = myScroll.maxScrollY - 5;
}else }else
{ {
myScroll.refresh(); refresh_scroll();
myScroll.maxScrollY = myScroll.maxScrollY - 5; //Hackish solution for not being able to scroll fully to the bottom, don't understand why this is fucked
} }
} }
} }
@@ -123,6 +122,12 @@ function skip(){
socket.emit('skip', [chan, guid]); socket.emit('skip', [chan, guid]);
} }
function refresh_scroll()
{
myScroll.refresh();
myScroll.maxScrollY = myScroll.maxScrollY - 5;
}
function show(){ function show(){
if(!window.mobilecheck()) if(!window.mobilecheck())
{ {