mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 20:26:24 +00:00
Fix scroll stickiness while hidden
Fix bug: Open thread A, open thread B, receive message in thread A, open thread A. Scroll bar has reset to the top.
This commit is contained in:
@@ -32,6 +32,9 @@
|
||||
this.scrollToBottom();
|
||||
},
|
||||
measureScrollPosition: function() {
|
||||
if (this.el.scrollHeight === 0) { // hidden
|
||||
return;
|
||||
}
|
||||
this.scrollPosition = this.$el.scrollTop() + this.$el.outerHeight();
|
||||
this.scrollHeight = this.el.scrollHeight;
|
||||
this.shouldStickToBottom = this.scrollPosition === this.scrollHeight;
|
||||
|
||||
Reference in New Issue
Block a user