diff options
author | Erin Dahlgren <edahlgren@google.com> | 2013-10-10 12:47:07 -0700 |
---|---|---|
committer | Erin Dahlgren <edahlgren@google.com> | 2013-10-10 14:25:29 -0700 |
commit | 62c72ca1b5d0a608d549615928d66e9d1911062f (patch) | |
tree | 4018d68e4b0c6e5156fb96193fc2df4183e48a55 /src/com/android/camera/ui/FilmStripView.java | |
parent | 23df6752f1bf0cc7d13b3aa68e87a8dde36af2d4 (diff) | |
download | android_packages_apps_Snap-62c72ca1b5d0a608d549615928d66e9d1911062f.tar.gz android_packages_apps_Snap-62c72ca1b5d0a608d549615928d66e9d1911062f.tar.bz2 android_packages_apps_Snap-62c72ca1b5d0a608d549615928d66e9d1911062f.zip |
Check both the requestId of current item and total items in filmstrip for bottom controls.
Bug: 11169201
Change-Id: I9d42b168efe62712f76165db5221757a1f20013f
Diffstat (limited to 'src/com/android/camera/ui/FilmStripView.java')
-rw-r--r-- | src/com/android/camera/ui/FilmStripView.java | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/com/android/camera/ui/FilmStripView.java b/src/com/android/camera/ui/FilmStripView.java index b6f83adf1..c4916c24b 100644 --- a/src/com/android/camera/ui/FilmStripView.java +++ b/src/com/android/camera/ui/FilmStripView.java @@ -1024,14 +1024,12 @@ public class FilmStripView extends ViewGroup implements BottomControlsListener { return; } - // We cannot rely on the requestIds to check for data changes, - // because an item hands its id to its rightmost neighbor on - // deletion. To avoid loading the ImageData, we check if the DataAdapter - // has fewer total items. We don't want to miss setting the controls - // for a photo while we're still in capture mode, so ignore its fixed - // requestId (0). + // We cannot rely on the requestIds alone to check for data changes, + // because an item hands its id to its rightmost neighbor on deletion. + // To avoid loading the ImageData, we also check if the DataAdapter + // has fewer total items. int total = mDataAdapter.getTotalNumber(); - if (!force && (requestId == 0 || mLastTotalNumber == total)) { + if (!force && requestId == mLastItemId && mLastTotalNumber == total) { return; } mLastTotalNumber = total; |