diff options
Diffstat (limited to 'static/js')
| -rwxr-xr-x | static/js/pichat.js | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/static/js/pichat.js b/static/js/pichat.js index d3da949..6b9c3e8 100755 --- a/static/js/pichat.js +++ b/static/js/pichat.js @@ -106,30 +106,12 @@ function ifEnter(fn) { }; } -/* -function isScrolledToBottom(div) { - return Math.abs(div.scrollTop - (div.scrollHeight - div.offsetHeight)) <= 3; -} - -function scrollToBottom(div) { - div.scrollTop = div.scrollHeight; -} - -// Give images time to start loading before scrolling. -// Needed until server knows size of images. -function delayedScrollToBottom(delay) { - setTimeout(scrollToBottom, delay, $('#messageList')[0]); -} -*/ - function addNewMessages(msgs) { - //var wasScrolledToBottom = isScrolledToBottom($('#messageList')[0]); var msgStr = $.map(msgs, buildMessageDiv).join(''); $('#messageList').append(msgStr); } function addNewMessage(msg, isLoading) { - //var wasScrolledToBottom = isScrolledToBottom($('#messageList')[0]); var msgStr = buildMessageDiv(msg, isLoading); var div = $(msgStr).appendTo('#messageList'); return div; |
