From 5704e581643f81a3a792daffa41be12a517f6f73 Mon Sep 17 00:00:00 2001 From: tibbi Date: Mon, 4 Jun 2018 23:12:53 +0200 Subject: [PATCH] do not even draw the Focus circle if the current camera doesnt support focus --- .../com/simplemobiletools/camera/views/PreviewCameraTwo.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/camera/views/PreviewCameraTwo.kt b/app/src/main/kotlin/com/simplemobiletools/camera/views/PreviewCameraTwo.kt index 072ae30e..40985115 100644 --- a/app/src/main/kotlin/com/simplemobiletools/camera/views/PreviewCameraTwo.kt +++ b/app/src/main/kotlin/com/simplemobiletools/camera/views/PreviewCameraTwo.kt @@ -80,7 +80,7 @@ class PreviewCameraTwo : ViewGroup, TextureView.SurfaceTextureListener, MyPrevie mDownEventAtX = event.x mDownEventAtY = event.y } else if (event.action == MotionEvent.ACTION_UP) { - if (System.currentTimeMillis() - mDownEventAtMS < CLICK_MS && + if (mIsFocusSupported && System.currentTimeMillis() - mDownEventAtMS < CLICK_MS && Math.abs(event.x - mDownEventAtX) < CLICK_DIST && Math.abs(event.y - mDownEventAtY) < CLICK_DIST) { focusArea(event.x, event.y)