[英]How work scrollview inside scrollview?
My Layout structure is like this 我的布局结构是这样的
<LinearLayout>
<scrollview>
<RelativeLayout>
<scrollview>
...
...
</scrollview>
</RelativeLayout>
</scrollview>
</LinearLayout>
But problem is that when we scroll inner scrollview outer scrollview also scrolling due to which I unable to scroll inner scrollview which contains 50 line And able to read only 10 line please anyone guide me,How I can Manage it. 但是问题是,当我们滚动内部滚动视图时,外部滚动视图也会滚动,因此我无法滚动包含50行的内部滚动视图,并且只能读取10行,请任何人指导我,我该如何管理它。
由于ListView具有内置的滚动,因此此做法将与ScrollView内部的ListView具有相同的模式(不适用于Android),那么您也可以参考此
If I do that for a scrollview inside scrollview it work very well (tested only for scrollview). 如果我在scrollview内的scrollview上执行此操作,则效果很好(仅针对scrollview进行了测试)。 I don't know if it's work for a listview.
我不知道它是否适用于列表视图。
@Override public boolean onInterceptTouchEvent(MotionEvent ev) { @Override public boolean onInterceptTouchEvent(MotionEvent ev){
if(getFocusedChild() != null) {
getParent().requestDisallowInterceptTouchEvent(true);
}
.... ....
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.