Open larham opened 12 years ago
This should already be possible. In one of my apps I have three different indicators - unless you're referring to them both pointing to the same viewpager?
thanks for clarifying.
yes, for the same viewpager, e.g., at bottom and top of display
How do you propose this be done? The indicators currently subscribe to the page change events from ViewPager
which only accepts a single listener at a time.
I can think of gross ways of doing this but I'm not going to implement them unless the 99.9999% case (single indicator per pager) is still easy.
This is probably one of the gross ways: but couldn't a pager subscribe to the page change events that another pager sends out?
Yes, as navarr suggested, one way would be for the PageIndicator.setViewPager() to have an analogous setParentIndicator() if the parent PageIndicator had a setOnPageChangeListener().
This is just a minor feature request. If the interfaces aren't sufficient, there isn't a justification for gross measures.
Ideally we could change ViewPager
to accept multiple observers. I may look into that first and contribute to AOSP for the next support library revision.
Any updates regarding implementing this feature?
Hey, attached my solution here: https://gist.github.com/AlmogBaku/7411ffa44030bc7c641d
This is a simple aggregator.. Nothing complex :)
@AlmogBaku You saved me. Exactly what i want. Thumbs up /////*
such as a title strip on top, and dots on bottom. currently, the last indicator "wins"--it shows, but first one does not.