A short Android snippet showing how to optimize ImageView performance in list/grid views by skipping unnecessary layout passes when displaying images of the same size. The technique, natively added in Android 4.0 (Ice Cream Sandwich), can be backported via a custom OptimisedImageView subclass that checks if the new drawable matches the current one's dimensions before calling requestLayout(), improving scrolling performance in AdapterViews.

3m read timeFrom chrisbanes.me
Post cover image
Table of contents
Scenario #Result #Code #TL;DR #