如何扭转viewPager的方向从左到右的顺序?顺序、方向、viewPager、左到右

由网友(君醉沙场)分享简介:我有viewPager几个观点。 viewPager的默认行为是第一个项目第一次显示,然后刷卡从右到左显示第二视图右侧当前视图等。I have viewPager with several views. the default behavior of viewPager is that the first item...

我有viewPager几个观点。 viewPager的默认行为是第一个项目第一次显示,然后刷卡从右到左显示第二视图右侧当前视图等。

I have viewPager with several views. the default behavior of viewPager is that the first item is displayed first, then swiping right to left displays the second view right to the current view etc.

我想要的行为是显示的第一个项目后,刷卡左至右将显示下一个视图的左当前项目。

the behavior i want is that after the first item is displayed, swiping left to right will display the next view left to the current item.

我搜索了很多为实现这一点,但没有结果巧妙的方式.. 在此先感谢。

i searched a lot for clever way to implement this but no results.. thanks in advance.

推荐答案

你为什么不扭转的名单,你鉴于寻呼机查看和使用 setCurrentItem(INT)或 setCurrentItem(INT,布尔)并设定最后一个在发射活动/片段。

why don't you reverse the list of you view in view pager and use setCurrentItem(int) or setCurrentItem(int,boolean) and set the last one at the launch of the activity/fragment..

阅读全文

相关推荐

最新文章