Closed Airyzz closed 6 days ago
Related to #243 , but wont close it yet as it currently only works if we want to jump to an even that is already loaded in current timeline. If the event is not yet loaded, this is a separate case which needs to be handled differently
works by rendering entire timeline offscreen and measuring offset to desired eventCame up with a way more elegant solution: by manipulating the display indices of events in the timeline, we can force an arbitrary event to be positioned at the center of the scroll view. Because of this, we can always assume that the event will begin at scroll position
0.0
and so we can simply scroll to0 + viewHeight/2
to end up with the event positioned in the center of the viewSuper happy with this approach!