Monday 15 July 2013

android - How to mark the current tab when user swipe on PageViewer -



android - How to mark the current tab when user swipe on PageViewer -

i'm having viewpager contains 3 views. when user click on tab, view chages correctly , tab bottom border mark selected. situation when user swipe(left or right) view changes expected tab not marked selected. need mark tab if user swipe.

is there anyway can forcefulness tab selected when user swipe between views?

if need code allow me know.

i think must implement ontabchangelistener in code. here show way i'm doing it.

implements tabhost.ontabchangelistener, viewpager.onpagechangelistener

and implement method:

public void onpageselected(int position) { //==== set tab mtabhost.setcurrenttab(position); }

android android-fragments android-viewpager swipe-gesture

No comments:

Post a Comment