Rerender views if necessary when scrolling horizontally

If the context says it wants to rerender when its width changes, we must also
rerender when the horizontal scroll position changes.
This commit is contained in:
Stefan Haller 2025-04-12 19:47:11 +02:00
parent 9e3e1a7b3a
commit fa9d75835c

View file

@ -74,6 +74,9 @@ func (self *ListController) scrollHorizontal(scrollFunc func()) error {
scrollFunc()
self.context.HandleFocus(types.OnFocusOpts{})
if self.context.NeedsRerenderOnWidthChange() == types.NEEDS_RERENDER_ON_WIDTH_CHANGE_WHEN_WIDTH_CHANGES {
self.context.HandleRender()
}
return nil
}