summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanny Baumann <dannybaumann@web.de>2016-03-27 13:41:15 +0200
committerDanny Baumann <dannybaumann@web.de>2016-03-29 00:19:15 -0700
commit6058c3806372a607f371438a5d132934a057ecc8 (patch)
tree7e1384cd73aa38513177b4bf6e5f7a85a02c39cf
parent6611f21d1fb9fecaf8dfc12ade9fa1e861cb57e2 (diff)
downloadandroid_packages_apps_Snap-6058c3806372a607f371438a5d132934a057ecc8.zip
android_packages_apps_Snap-6058c3806372a607f371438a5d132934a057ecc8.tar.gz
android_packages_apps_Snap-6058c3806372a607f371438a5d132934a057ecc8.tar.bz2
Fix histogram not being hidden after disabling it.
Change-Id: I55aef506f2cc5c142964c7e90714a2c56aa3de89
-rw-r--r--src/com/android/camera/ui/CameraControls.java2
-rw-r--r--src/com/android/camera/ui/HistogramView.java1
2 files changed, 2 insertions, 1 deletions
diff --git a/src/com/android/camera/ui/CameraControls.java b/src/com/android/camera/ui/CameraControls.java
index adaf342..0c64697 100644
--- a/src/com/android/camera/ui/CameraControls.java
+++ b/src/com/android/camera/ui/CameraControls.java
@@ -698,7 +698,7 @@ public class CameraControls extends RotatableLayout {
public void setHistogramEnabled(boolean enabled, CameraManager.CameraProxy camera) {
mHistogramView.setVisibility(enabled ? View.VISIBLE : View.GONE);
- mHistogramView.setCamera(camera);
+ mHistogramView.setCamera(enabled ? camera : null);
}
public void updateHistogramData(int[] data) {
diff --git a/src/com/android/camera/ui/HistogramView.java b/src/com/android/camera/ui/HistogramView.java
index 822233c..9687e42 100644
--- a/src/com/android/camera/ui/HistogramView.java
+++ b/src/com/android/camera/ui/HistogramView.java
@@ -59,6 +59,7 @@ public class HistogramView extends View {
mGraphCameraDevice = camera;
if (camera == null) {
mDataValid = false;
+ invalidate();
}
}