Fix #581 Don't scroll chat automatically if user is not at the bottom
parent
6726ea6632
commit
8a471e590a
|
@ -62,9 +62,10 @@ var chat = (function()
|
|||
},
|
||||
scrollDown: function()
|
||||
{
|
||||
if($('#options-scrollchat').is(':checked')){
|
||||
if($('#chatbox').css("display") != "none"){
|
||||
if($('#chatbox').css("display") != "none"){
|
||||
if(!self.lastMessage || self.lastMessage.position().top < $('#chattext').height()) {
|
||||
$('#chattext').animate({scrollTop: $('#chattext')[0].scrollHeight}, "slow");
|
||||
self.lastMessage = $('#chattext > p').eq(-1);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue