查看 scrollToOffset的API说明
!#en Scroll with an offset related to the ScrollView's top left origin, if timeInSecond is omitted, then it will jump to the specific offset immediately.
!#zh 视图内容在规定时间内将滚动到 ScrollView 相对左上角原点的偏移位置, 如果 timeInSecond参数不传,则立即滚动到指定偏移位置。
按这个说明,如果要向左滚动视图100,应该scrollToOffset(Vec2(-100, 0)),可是实际情况确实要scrollToOffset(Vec2(100, 0)),看内部代码滚动的值不应该小于0,那么这文档就有问题
可是当scrollToOffset(Vec2(100, 0))向左滚动了100后,再调用getScrollOffset获取滚动偏移时,返回的却是
Vec2(-100, 0)