0

With the old SwipeyTabs you could just simply use the onSwipeyTabSelected.onSwipeyTabSelected, now android released at june 2012 the PageTabStrip, which it is supossed to ease the work, and in fact it does for simple cases. But i haven't found any method that in fact allows me to detect the Selection of a tab, in example:

_______________________________
| |Tab1| Tab2|
_______________________________

if i swipe to the right and the Tab2 got selected:

_______________________________
|Tab1 |Tab2| Tab3|
_______________________________

How can i detect/trigger an event in my activity containing the PagerTabStrip that this tab was selected?

P.S. Forgive me the crappy ascii art :D

4

1 に答える 1

3

PagerTabStripはに関連付けられており、ViewPagerの内容を変更するため、ビアViewPagerに登録することができます。ViewPager.OnPageChangeListenerViewPager setOnPageChangeListener()

あなたの議論が「まあ、彼らがポケットベルの本体をスワイプする場合とタブを介してスワイプする場合とは異なることをしたい」なら、私はそのUXのファンではありません。

于 2012-08-16T21:24:38.260 に答える