Android slide left right UI -
i trying create android ui sliding feature in middle of screen. have mainacitivity.java , trying figure out how can done. there command in sdk?. see sample slide entire activity screen not within activity. can guys provide ideas on how this. thanks
you can utilize viewpager... not necesary utilize fragments.
<android.support.v4.view.viewpager android:id="@+id/pager" android:layout_width="match_parent" android:layout_height="0px" android:layout_weight="1" > </android.support.v4.view.viewpager> <linearlayout android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_weight="0" android:gravity="center" android:measurewithlargestchild="true" android:orientation="horizontal" > <button android:id="@+id/first" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="about image" > </button> <button android:id="@+id/last" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="some other text" > </button> </linearlayout>
here example. http://www.androidbegin.com/tutorial/android-viewpager-gallery-images-and-texts-tutorial/
here illustration using viewpager fragments : http://manishkpr.webheavens.com/android-viewpager-example/
android android-layout android-activity android-fragments android-sliding
No comments:
Post a Comment