Android : Making Listview full screen -


<linearlayout 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:orientation="vertical"  tools:context=".mainactivity">  <edittext     android:layout_margintop="5dp"     android:layout_width="match_parent"     android:layout_height="50dp"     android:background="@drawable/location_edittext"     android:id="@+id/locationeditext"     android:textsize="15sp"     android:textcolor="#999"     android:paddingleft="15dp" />   <com.example.ravi_gupta.slider.viewpagercustomduration     android:layout_width="wrap_content"     android:layout_height="0dp"     android:id="@+id/viewpager"     android:scrollbarstyle="outsideoverlay"     android:layout_weight="0.5"> </com.example.ravi_gupta.slider.viewpagercustomduration>  <listview     android:layout_weight="0.50"     android:layout_below="@+id/viewpager"     android:layout_margintop="2dp"     android:layout_width="match_parent"     android:layout_height="45dp"     android:id="@+id/shoplistview" /> 

this code in activity.main i, want when scroll listview take space in layout hiding viewpager , editext , when scroll shows both of them, don't know how can possible, either should use relative layout or other method

you cannot depend on layout. modify code , @ setvisibility method @ setvisibility of view. example, if method set gone edittext ui, ui hidden if never shown. , of course, should set visible when appropriate.


Comments

Popular posts from this blog

javascript - Parse JSON from the body of the POST -

javascript - Chrome Extension: Interacting with iframe embedded within popup -