Run when the scroll frame's scroll position is changed. Only run when the scroll position changes due to changes in the scroll child frame's dimensions, not when
:SetVerticalScroll() is called.
self- Reference to the widget for which the script was run (
xOffset- New horizontal scroll range (in pixels, measured from the leftmost scroll position) (
yOffset- New vertical scroll range (in pixels, measured from the topmost scroll position) (
-- Set the min and max values of a scroll bar (Slider) based on the scroll range scrollFrame:SetScript("OnScrollRangeChanged", function(self, x, y) verticalScrollBar:SetMinMaxValues(0, y) end)