diff --git a/layout/generic/nsGfxScrollFrame.cpp b/layout/generic/nsGfxScrollFrame.cpp index 4768945a212..0436c2e99da 100644 --- a/layout/generic/nsGfxScrollFrame.cpp +++ b/layout/generic/nsGfxScrollFrame.cpp @@ -2934,10 +2934,6 @@ void nsGfxScrollFrameInner::CurPosAttributeChanged(nsIContent* aContent) (mVScrollbarBox && mVScrollbarBox->GetContent() == aContent), "unexpected child"); - if (mScrollbarActivity) { - mScrollbarActivity->ActivityOccurred(); - } - // Attribute changes on the scrollbars happen in one of three ways: // 1) The scrollbar changed the attribute in response to some user event // 2) We changed the attribute in response to a ScrollPositionDidChange @@ -2970,6 +2966,10 @@ void nsGfxScrollFrameInner::CurPosAttributeChanged(nsIContent* aContent) return; } + if (mScrollbarActivity) { + mScrollbarActivity->ActivityOccurred(); + } + bool isSmooth = aContent->HasAttr(kNameSpaceID_None, nsGkAtoms::smooth); if (isSmooth) { // Make sure an attribute-setting callback occurs even if the view