summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorkaiyiz <kaiyiz@codeaurora.org>2014-12-08 16:51:21 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2015-01-03 20:48:27 -0800
commit7996c173550c744813663f79e4c7bfbc274d7bd7 (patch)
treeb1941ae4a541c4fa607c4f2ce1b44b2d27570ba9 /src
parent8165fd7f2714fed319b00c09440e817f1d85b043 (diff)
downloadandroid_packages_apps_Gallery2-7996c173550c744813663f79e4c7bfbc274d7bd7.tar.gz
android_packages_apps_Gallery2-7996c173550c744813663f79e4c7bfbc274d7bd7.tar.bz2
android_packages_apps_Gallery2-7996c173550c744813663f79e4c7bfbc274d7bd7.zip
Gallery2: Fix crop after straighten bug
During straighten and crop, there will be a crop Rect exits, the comparement of these two Rect is not perfect, so the two rect is considered to be different, and the Representation is wrong. Set the origenal Rect equals to representation. CRs-Fixed: 766877 Change-Id: Id76dfef360cdaff109cdce505cb5f289691645c6
Diffstat (limited to 'src')
-rw-r--r--src/com/android/gallery3d/filtershow/filters/FilterCropRepresentation.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/com/android/gallery3d/filtershow/filters/FilterCropRepresentation.java b/src/com/android/gallery3d/filtershow/filters/FilterCropRepresentation.java
index ba697d87f..98afc3a08 100644
--- a/src/com/android/gallery3d/filtershow/filters/FilterCropRepresentation.java
+++ b/src/com/android/gallery3d/filtershow/filters/FilterCropRepresentation.java
@@ -65,6 +65,9 @@ public class FilterCropRepresentation extends FilterRepresentation {
return false;
}
FilterCropRepresentation crop = (FilterCropRepresentation) rep;
+ if (crop.isNil()) {
+ return true;
+ }
if (mCrop.bottom != crop.mCrop.bottom
|| mCrop.left != crop.mCrop.left
|| mCrop.right != crop.mCrop.right