0 down vote favorite
I have a problem which is disable and enable scrollView by code. This is my layout which includes header, footer and scrollview. The scrollview contain imageView and MapView. I used scrollview to scroll image and MapView because height total of their larger than height of screen. I want to disable scrollview if I touch map and move in the map. And it is enable when I touch ImageView. So, I will listen even touch and move in the map to enable and disable scrollview.But I try to use setEnable and setHorizontalScrollBarEnabled,setVerticalScrollBarEnabled method to do it but not success. Can you help me please.
I have a problem which is disable and enable scrollView by code. This is my layout which includes header, footer and scrollview. The scrollview contain imageView and MapView. I used scrollview to scroll image and MapView because height total of their larger than height of screen. I want to disable scrollview if I touch map and move in the map. And it is enable when I touch ImageView. So, I will listen even touch and move in the map to enable and disable scrollview.But I try to use setEnable and setHorizontalScrollBarEnabled,setVerticalScrollBarEnabled method to do it but not success. Can you help me please.
PHP:
<RelativeLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="@color/white" android:orientation="vertical"> <!-- Header --> <RelativeLayout android:id="@+id/header_content" android:layout_width="match_parent" android:layout_height="50dp" android:layout_alignParentTop="true" >
<!-- Footer --> <RelativeLayout android:id="@+id/footer_content" android:layout_width="match_parent" android:layout_height="50dp" android:layout_alignParentBottom="true" > </RelativeLayout> <ScrollView android:id="@+id/ScrollView01" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_above="@+id/footer_content" android:layout_below="@+id/header_content" > <RelativeLayout android:id="@+id/contentImage" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > <ImageView android:id="@+id/imagelocation" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_gravity="center" android:scaleType="fitCenter" /> <RelativeLayout android:id="@+id/RelMap" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_below="@+id/imagelocation" > <com.nhn.android.maps.NMapView android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/mapView"/> </RelativeLayout>

