On Sat, Jul 2, 2011 at 10:14 AM, Simon Platten <[email protected]> wrote: > I can't call rotateThumbnail directly from getView as it is the result of an > onClick from one of the buttons also in the view for that item.
Then why are you expecting your images to be rotated when you return a row from getView(), if you are not rotating them? > The ImageView that is rotated is from the array that the list view uses. No, it is not, at least not based on the code that you pasted above. Which is good, because maintaining an array of ImageViews would be a bad move. You are getting your ImageView via: ImageView ivThumbnail = (ImageView)v.findViewById(R.id.ivthumbNail); This is returning the ImageView from the row (recycled or newly inflated). It is not from "the array that the list view uses". You are setting the background of this ImageView to a *newly decoded bitmap* from your file. That too is sub-optimal code, as it means you are performing disk I/O on the main application thread on every getView() call, so your scrolling will be sluggish. Moreover, you are not rotating the image here, so therefore it will not be rotated, since it is a *newly decoded bitmap*. If you want to rotate your image, then please rotate your image. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.5 Available! -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

