diff options
author | Erin Dahlgren <edahlgren@google.com> | 2013-10-11 01:30:32 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2013-10-11 01:30:32 +0000 |
commit | 36c21ca1365c0c3832742bc0cf75d3409723254b (patch) | |
tree | aff6ece4a023b3b1918c1bf36758673a8f484fd1 /src | |
parent | d70f0fb68064e170fb2cf041a707ed04d68040f9 (diff) | |
parent | 62c72ca1b5d0a608d549615928d66e9d1911062f (diff) | |
download | android_packages_apps_Snap-36c21ca1365c0c3832742bc0cf75d3409723254b.tar.gz android_packages_apps_Snap-36c21ca1365c0c3832742bc0cf75d3409723254b.tar.bz2 android_packages_apps_Snap-36c21ca1365c0c3832742bc0cf75d3409723254b.zip |
Merge "Check both the requestId of current item and total items in filmstrip for bottom controls." into gb-ub-photos-carlsbad
Diffstat (limited to 'src')
-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 3e29dc0d3..e32cccf68 100644 --- a/src/com/android/camera/ui/FilmStripView.java +++ b/src/com/android/camera/ui/FilmStripView.java @@ -1027,14 +1027,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; |