[英]Horizontal ScrollView full Scroll focus right with ViewTreeObserver
[英]Horizontal scrollview scroll changes tab focus
我在水平scrollview中有一個選項卡小部件。 我有的問題是,當我在滾動視圖中滾動時,選項卡小部件中的當前選項卡會更改,並且因為執行了此ontabchange事件處理程序。
為了阻止這個,我試圖處理滾動視圖的ontouchevent,它滾動選項卡並返回true。 但不能完全做到這一點。
有人可以幫忙嗎?
提前致謝!
在選項卡xml中嘗試一下
<HorizontalScrollView
android:layout_width="fill_parent"
android:layout_height="200dp">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="200dp"
android:orientation="horizontal">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/src" />
</LinearLayout>
</HorizontalScrollView>
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.