Android 无休止地滚动滚动视图

Android 无休止地滚动滚动视图,android,scrollview,Android,Scrollview,我有以下自定义水平滚动视图。问题是,它只从右向左完全滚动,而不是从左向右滚动,即当图像设置到其原始位置时,在一侧滚动完成。我想在这两个方向上做同样的运动 <com.custom xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/outerScroll1" android:layout_widt

我有以下自定义水平滚动视图。问题是,它只从右向左完全滚动,而不是从左向右滚动,即当图像设置到其原始位置时,在一侧滚动完成。我想在这两个方向上做同样的运动

 <com.custom
                xmlns:android="http://schemas.android.com/apk/res/android"
                android:id="@+id/outerScroll1"
                android:layout_width="1500dip"
                android:layout_height="200dip"
                android:layout_alignParentLeft="true"
                android:fitsSystemWindows="true"
                android:scrollX="300dip"
                >
    <RelativeLayout
                    android:layout_width="1500dip"
                      android:layout_height="200dip" 
                      >
                  <ImageView
                        android:id="@+id/imageView1"
                        android:layout_width="500dip"
                        android:layout_height="200dip"
                        android:scaleType="fitXY"
                        android:src="@drawable/pic"
                         />
                </RelativeLayout>

           </com.custom>


我试过滑动抽屉,但没用。甚至我在自定义视图中使用了
android:layout\u centerHorizontal=“true”
,但这些改变了视图的位置,即滑动视图

你能把你的java代码发送到滚动视图的地方吗?