From 716b7fbfec9b820652f633d1e74ca87a2e11283c Mon Sep 17 00:00:00 2001 From: tibbi Date: Wed, 14 Sep 2022 19:42:26 +0200 Subject: [PATCH] use a better scaling type for widget previews --- .../com/simplemobiletools/launcher/adapters/WidgetsAdapter.kt | 1 - app/src/main/res/layout/item_widget_preview.xml | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/launcher/adapters/WidgetsAdapter.kt b/app/src/main/kotlin/com/simplemobiletools/launcher/adapters/WidgetsAdapter.kt index bbc439e..8b2399b 100644 --- a/app/src/main/kotlin/com/simplemobiletools/launcher/adapters/WidgetsAdapter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/launcher/adapters/WidgetsAdapter.kt @@ -84,7 +84,6 @@ class WidgetsAdapter( Glide.with(activity) .load(widget.widgetPreviewImage) - .fitCenter() .into(widgetPreview) widgetPreview.setOnClickListener { diff --git a/app/src/main/res/layout/item_widget_preview.xml b/app/src/main/res/layout/item_widget_preview.xml index 8f283c8..f416509 100644 --- a/app/src/main/res/layout/item_widget_preview.xml +++ b/app/src/main/res/layout/item_widget_preview.xml @@ -5,6 +5,7 @@ android:layout_width="@dimen/widget_preview_size" android:layout_height="@dimen/widget_preview_size" android:layout_gravity="center" + android:scaleType="centerInside" android:adjustViewBounds="true" android:background="@drawable/widget_preview_background" android:padding="@dimen/normal_margin"