From bf474a5eef777c0b19a09ece26992c518e4308e5 Mon Sep 17 00:00:00 2001 From: Nik Clayton Date: Tue, 30 Apr 2024 16:14:11 +0200 Subject: [PATCH] fix(deps): update dependency androidx.core:core-ktx to v1.13.0 (#673) Use `GestureDetector` as this release deprecates `GestureDetectorCompat`. --- app/src/main/java/app/pachli/fragment/ViewImageFragment.kt | 3 +-- app/src/main/java/app/pachli/fragment/ViewVideoFragment.kt | 3 +-- gradle/libs.versions.toml | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/app/pachli/fragment/ViewImageFragment.kt b/app/src/main/java/app/pachli/fragment/ViewImageFragment.kt index a8786bef7..a531422c6 100644 --- a/app/src/main/java/app/pachli/fragment/ViewImageFragment.kt +++ b/app/src/main/java/app/pachli/fragment/ViewImageFragment.kt @@ -29,7 +29,6 @@ import android.view.View import android.view.ViewGroup import android.widget.ImageView import androidx.coordinatorlayout.widget.CoordinatorLayout -import androidx.core.view.GestureDetectorCompat import androidx.core.view.ViewCompat import androidx.lifecycle.Lifecycle import androidx.lifecycle.lifecycleScope @@ -82,7 +81,7 @@ class ViewImageFragment : ViewMediaFragment() { override fun onViewCreated(view: View, savedInstanceState: Bundle?) { super.onViewCreated(view, savedInstanceState) - val singleTapDetector = GestureDetectorCompat( + val singleTapDetector = GestureDetector( requireContext(), object : GestureDetector.SimpleOnGestureListener() { override fun onDown(e: MotionEvent) = true diff --git a/app/src/main/java/app/pachli/fragment/ViewVideoFragment.kt b/app/src/main/java/app/pachli/fragment/ViewVideoFragment.kt index 05a421538..de8406485 100644 --- a/app/src/main/java/app/pachli/fragment/ViewVideoFragment.kt +++ b/app/src/main/java/app/pachli/fragment/ViewVideoFragment.kt @@ -33,7 +33,6 @@ import android.view.ViewGroup import android.widget.FrameLayout import android.widget.LinearLayout import androidx.annotation.OptIn -import androidx.core.view.GestureDetectorCompat import androidx.core.view.ViewCompat import androidx.lifecycle.lifecycleScope import androidx.media3.common.MediaItem @@ -134,7 +133,7 @@ class ViewVideoFragment : ViewMediaFragment() { var wasPlaying: Boolean? = null /** Handle taps and flings */ - val simpleGestureDetector = GestureDetectorCompat( + val simpleGestureDetector = GestureDetector( requireContext(), object : GestureDetector.SimpleOnGestureListener() { override fun onDown(e: MotionEvent) = true diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index ab6a70b4a..5db936cd5 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -7,7 +7,7 @@ androidx-appcompat = "1.6.1" androidx-browser = "1.8.0" androidx-cardview = "1.0.0" androidx-constraintlayout = "2.1.4" -androidx-core = "1.12.0" +androidx-core = "1.13.0" androidx-exifinterface = "1.3.7" androidx-fragment = "1.6.2" androidx-hilt = "1.2.0"