1

Using sdk version 8, with android-support-v4, I am trying to make implement a PagerAdapter that shows multiple pages at once.

Found some good advice online, that indicated the best way to achieve this is to override the getPageWidth(int) method on PagerAdapter.

http://commonsware.com/blog/2012/08/20/multiple-view-viewpager-options.html

However, PagerAdapter does not have that method in the android-support-v4.jar. I can't figure out why, since androids own documentation does confirm the existence of that method.

http://developer.android.com/reference/android/support/v4/view/PagerAdapter.html#getPageWidth(int)

The problem of course if that if the method doesn't exist, it makes no sense to override it as it would never be called.

Any ideas?

4

1 回答 1

2

Your JAR is out of date, presumably. Make sure that you are on the latest Android Support package. Or, grab the JAR from the sample project that I linked to in the blog post.

于 2012-11-04T17:52:32.583 回答