From 5ae6532b568d0be90e5b1b53178e7d7927529201 Mon Sep 17 00:00:00 2001 From: Andreas Huber <> Date: Tue, 24 Mar 2009 18:39:29 -0700 Subject: Automated import from //branches/donutburger/...@140831,140831 --- src/com/android/camera/ViewImage.java | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src') diff --git a/src/com/android/camera/ViewImage.java b/src/com/android/camera/ViewImage.java index 2e777fd..1376172 100644 --- a/src/com/android/camera/ViewImage.java +++ b/src/com/android/camera/ViewImage.java @@ -201,6 +201,17 @@ public class ViewImage extends Activity implements View.OnClickListener mZoomButtonsController.setZoomOutEnabled(scale > 1); } + @Override + protected void onDestroy() { + // This is necessary to make the ZoomButtonsController unregister + // its configuration change receiver. + if (mZoomButtonsController != null) { + mZoomButtonsController.setVisible(false); + } + + super.onDestroy(); + } + private void setupZoomButtonController(View rootView) { mGestureDetector = new GestureDetector(this, new MyGestureListener()); mZoomButtonsController = new ZoomButtonsController(rootView); -- cgit v1.1