If I reset currentPage = 0 here, the animation freezes on the first image
Am I doing something wrong?
Compare what is printed for when it works and what is printed when it fails.
When and why is destroyItem called?
Can you control when it is called?
Was the first call to destroyItem in response to a user's action after the animation had run for a while?
It is hard to guess what was happening on the device with only those small sections of the logcat posted here
What causes destroyItem() to be called?
Can you run the code again and allow the animation to wrap around at least once and then somehow show a call to destroyItem().
Copy that contents of the logcat and paste it here.
I am unable to understand why ?
09-20 19:53:05.083: I/System.out(8046): >>>>>>>>>> Started at Fri Sep 20 19:53:05 GMT 2013
09-20 19:53:05.147: I/System.out(8046): screen size=Point(1024, 552), inches=7.281629740932256
09-20 19:53:05.155: I/System.out(8046): xdpi=159.5681, ydpi=160.42105 wPix=1024, hPix=552, test48dp=48, dp=48, density=1.0
09-20 19:53:05.219: I/System.out(8046): cf to sk dist=20.003796, bearing=-152.31781, miles2=6466.4526 [1.0406721E7, 37.526474, 142.32643]
09-20 19:53:06.959: I/System.out(8046): onCreateOptionsMenu
09-20 19:53:06.975: I/System.out(8046): onPrepareOptionsMenu
09-20 19:53:07.135: D/gralloc_vbox86(8046): Emulator without GPU emulation detected.
09-20 19:53:07.519: I/Choreographer(8046): Skipped 45 frames! The application may be doing too much work on its main thread.
09-20 19:53:17.851: I/System.out(8046): onPrepareOptionsMenu
09-20 19:53:22.463: I/System.out(8046): onOptionsItemSelected item=Show Fragment menu
09-20 19:53:22.723: I/System.out(8046): MDF onCreate() passed=passed string
09-20 19:53:24.347: I/System.out(8046): onItemSelected arg1=android.widget.TextView{a6645b10 V.ED.... ......ID 4,10-60,32 #1020014 android:id/text1}, pos=0, is=0
09-20 19:53:35.575: I/System.out(8046): onItemSelected arg1=android.widget.TextView{a6652f18 V.ED.... ......I. 4,10-60,32 #1020014 android:id/text1}, pos=4, is=4
09-20 19:53:40.875: I/System.out(8046): setChoice s=item4
09-20 19:53:50.163: I/Choreographer(8046): Skipped 48 frames! The application may be doing too much work on its main thread.
09-20 19:53:53.819: I/System.out(8046): <<<<<<<<<<<<< Stopped at Fri Sep 20 19:53:53 GMT 2013
Where is the code that adds anything to myImages? I do not see any add statements for myImages
Did you try?
I did as you suggested
The only taste of success some people get is to take a bite out of you. Or this tiny ad:
Low Tech Laboratory
https://www.kickstarter.com/projects/paulwheaton/low-tech-0
|