Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在一个活动中有一个按钮,在第二个活动中有一个滚动视图滚动视图里面有很多视图。当我单击第一个活动中的按钮时,会调用第二个活动,但滚动视图会自动滚动到滚动视图的中心。我想显示手动向下滚动的第二个视图的顶部。
您可以以编程方式将滚动视图滚动到某个位置。只需在第二个活动开始时使用 yourScrollView.scrollTo(0,0) 即可。希望这可以帮助。