當我在我的模擬器上測試我的應用程序(具有水平滾動視圖)時,滾動部分在中間凍結。有時,當我以另一種方式滾動時滾動會凍結。應用程序不會因爲後退按鈕的作用而凍結。這會凍結在實際的Android設備上,還是這只是我的模擬器反應?Android Studio:水平滾動視圖在模擬器上測試時凍結
這裏是我的滾動活動代碼:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
android:paddingBottom="@dimen/activity_vertical_margin"
tools:context="namee.com.myapp.School"
android:background="#000000">
<HorizontalScrollView android:id="@+id/horizontalScroll"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:fadingEdgeLength="20dp"
android:background="#000000">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="#000000">
<ImageView android:src="@drawable/sunset3" android:layout_height="354dp" android:layout_width="600dp" />
<ImageView android:src="@drawable/sunset3" android:layout_height="354dp" android:layout_width="600dp" />
<ImageView android:src="@drawable/sunset3" android:layout_height="354dp" android:layout_width="600dp" />
</LinearLayout>
</HorizontalScrollView>
這裏是sunset3
http://postimg.org/image/5l69hadel/
只是佈局沒有人可以告訴問題在哪裏。發佈Java代碼或堆棧跟蹤(如果有的話)。 – Gumbo 2014-08-29 21:33:46
@Gumbo沒有.java,它只是在活動中。 – MGames 2014-08-29 21:35:28
@Gumbo它真的類似於這個:https://www.youtube.com/watch?v = 0PAsR5sIi6E – MGames 2014-08-29 21:36:17