From 77a4482263f137a76a6a606757ea3dafa8ac87d9 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Thu, 12 Feb 2015 17:16:49 -0700 Subject: [PATCH] Fix assignment of oldState values in ScrollbarComponent Signed-off-by: Max Brunsfeld --- src/scrollbar-component.coffee | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/scrollbar-component.coffee b/src/scrollbar-component.coffee index dbad89cf7..8eef5c3e6 100644 --- a/src/scrollbar-component.coffee +++ b/src/scrollbar-component.coffee @@ -42,11 +42,11 @@ class ScrollbarComponent if @newState.scrollTop isnt @oldState.scrollTop @domNode.scrollTop = @newState.scrollTop - @oldState = @newState.scrollTop + @oldState.scrollTop = @newState.scrollTop if @newState.scrollHeight isnt @oldState.scrollHeight @contentNode.style.height = @newState.scrollHeight + 'px' - @oldState = @newState.scrollHeight + @oldState.scrollHeight = @newState.scrollHeight updateHorizontal: -> if @newState.height isnt @oldState.height @@ -59,11 +59,11 @@ class ScrollbarComponent if @newState.scrollLeft isnt @oldState.scrollLeft @domNode.scrollLeft = @newState.scrollLeft - @oldState = @newState.scrollLeft + @oldState.scrollLeft = @newState.scrollLeft if @newState.scrollWidth isnt @oldState.scrollWidth @contentNode.style.width = @newState.scrollWidth + 'px' - @oldState = @newState.scrollWidth + @oldState.scrollWidth = @newState.scrollWidth onScrollCallback: => switch @orientation