From 78edd6400741789f03261d9a2d573a22a4d05013 Mon Sep 17 00:00:00 2001 From: Harrison Oglesby Date: Tue, 14 Mar 2023 15:22:27 -0700 Subject: [PATCH] Bug 1809809 - debounce click events on wallpaper settings --- .../org/mozilla/fenix/settings/wallpaper/WallpaperSettings.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/org/mozilla/fenix/settings/wallpaper/WallpaperSettings.kt b/app/src/main/java/org/mozilla/fenix/settings/wallpaper/WallpaperSettings.kt index fe9c46753d..d4e3d767ab 100644 --- a/app/src/main/java/org/mozilla/fenix/settings/wallpaper/WallpaperSettings.kt +++ b/app/src/main/java/org/mozilla/fenix/settings/wallpaper/WallpaperSettings.kt @@ -10,7 +10,6 @@ import androidx.compose.foundation.BorderStroke import androidx.compose.foundation.Image import androidx.compose.foundation.background import androidx.compose.foundation.border -import androidx.compose.foundation.clickable import androidx.compose.foundation.layout.Box import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.Row @@ -51,6 +50,7 @@ import androidx.compose.ui.tooling.preview.Preview import androidx.compose.ui.unit.dp import org.mozilla.fenix.R import org.mozilla.fenix.compose.ClickableSubstringLink +import org.mozilla.fenix.compose.ext.debouncedClickable import org.mozilla.fenix.theme.FirefoxTheme import org.mozilla.fenix.wallpapers.Wallpaper @@ -300,7 +300,7 @@ private fun WallpaperThumbnailItem( .fillMaxWidth() .aspectRatio(aspectRatio) .then(border) - .clickable { onSelect(wallpaper) } + .debouncedClickable { onSelect(wallpaper) } .then(contentDescriptionModifier), ) { bitmap?.let {