emilsjolander / android-FlipView

A small, easy to use android library for implementing flipping between views as seen in the popular Flipboard application
Apache License 2.0
923 stars 273 forks source link

FlipView with ViewPager inside misbehaves #19

Closed rahulkapoor1 closed 11 years ago

rahulkapoor1 commented 11 years ago

Thanks for your nice library. But if i use ViewPager inside FlipView then the content of the ViewPager is not visible till i touch the area of ViewPager. I didnot changed your code, I just try to implement ViewPager inslide Flip. That Issue is happening every time when i go the next page. And is that possible to stop the movement of first page. I upload video on youtube to show that only the VewPager's text appears when i touched the pager's area. Here is the link https://www.youtube.com/watch?v=4YY4MeIl4rI&feature=youtu.be

JackDanyels commented 11 years ago

Try out a HorizontalscrollView instead of ViewPager.

JackDanyels commented 11 years ago

or you just wait, emilsjolander claimed that he is working on a new version, it might solve your issue.

emilsjolander commented 11 years ago

Not really sure what the problem is. Will experiment after i am done with the new version ;)

You can't stop the first page from flipping. you can however not start flipping it be not calling

void peakNext(boolean once);
rahulkapoor1 commented 11 years ago

JackDanyels i am using horizontalpager(https://github.com/ysamlan/horizontalpager). And it working fine but still not know what the actual issue was when i was using ViewPager. Emilsjolander if you have some free time then must give a option for first page movement.

JackDanyels commented 11 years ago

Yeah I had a similar issue and was not able to figure out the reason. It might be to complex in the view-hirachy. What do you mean by stopping the movemoent of first page...do you want to disable the FlipView after you flipped once?

rahulkapoor1 commented 11 years ago

No JackDanyles i dont want to disable FlipView. When the application starts we can see that the page is animated (Automatic flipping on first page). As emils said i use the peakNext(true); but still it flip one time and then it stop.

JackDanyels commented 11 years ago

according to the javadoc, peakNext(true) triggers one flip and disables the peaking afterwards. If you use peakNext(false) it will keep peaking until the user interacts. If you only want to peak on the very first time you start the app, you need save the information that the app has been launched. SharedPrefrences? Or am I still not getting the issue ? :)

rahulkapoor1 commented 11 years ago

JackDanyels i dont want peak on first time either one time.

JackDanyels commented 11 years ago

Ok...I don't know why, but in my App it does not peak even once

emilsjolander commented 11 years ago

@rahulkapoor1 just do not call peakNext(). delete that line!

emilsjolander commented 11 years ago

and i suggest you read the docs

JackDanyels commented 11 years ago

Just to drop in as info, the reason why peaking was not triggered in my app was, that i'm loading all the content async. So when peak was triggered the data was not yet loaded and no further pages available. Now I just call peakNext() when the loading process is complete.

rahulkapoor1 commented 11 years ago

Thanks emilsjolander for your wonderful library. Its fixed.:)

emilsjolander commented 11 years ago

@rahulkapoor1 you can close your own issues just so you know ;)

rahulkapoor1 commented 11 years ago

ok emil sorry i forget to close. once again thanks for your library.:)