mirror of
https://github.com/onionshare/onionshare.git
synced 2025-12-14 15:58:59 -05:00
working on making the scrollbar appear in the right place
This commit is contained in:
parent
5865fd60ea
commit
3e65bf7884
2 changed files with 12 additions and 7 deletions
|
|
@ -6,6 +6,7 @@ $(function(){
|
|||
$('#log').append($line);
|
||||
|
||||
// scroll to bottom
|
||||
set_log_height();
|
||||
$('#log').scrollTop($('#log').height());
|
||||
}
|
||||
|
||||
|
|
@ -115,4 +116,12 @@ $(function(){
|
|||
});
|
||||
}
|
||||
});
|
||||
|
||||
// make sure the log always has a height set, so it will have its own scrollbar
|
||||
function set_log_height() {
|
||||
var new_height = $(document).height() - 140; // header = 100, footer = 40
|
||||
$('#log').css('height', new_height);
|
||||
}
|
||||
set_log_height();
|
||||
$.resize(set_log_height);
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue