Update scrollTop to valid position when scrollbar disappears

This commit is contained in:
Nathan Sobo
2014-04-23 14:13:19 -06:00
parent c4be32a5dd
commit d9ba9262bf
2 changed files with 2 additions and 2 deletions

View File

@@ -130,6 +130,7 @@ class DisplayBuffer extends Model
oldWidth = @width
@width = newWidth
@updateWrappedScreenLines() if newWidth isnt oldWidth and @softWrap
@setScrollTop(@getScrollTop()) # Ensure scrollTop is still valid in case horizontal scrollbar disappeared
@width
getScrollTop: -> @scrollTop