Add spacing between items as decorations instead of margins
There are bugs in the accounting for the margins if we manipulate the
view directly, causing the wrong top to be reported and the view to be
shifted when we call scrollToPosition. Item decorations ensure that the
layout system for the recycler view always has the right details about
the spacing.
Fix: 191642682
Test: verified locally
Change-Id: Ie80563757079e885c8178883ab16e314d01c5b32
diff --git a/res/values/dimens.xml b/res/values/dimens.xml
index 251f04a..416179e 100644
--- a/res/values/dimens.xml
+++ b/res/values/dimens.xml
@@ -147,7 +147,7 @@
<dimen name="widget_list_content_corner_radius">4dp</dimen>
<dimen name="widget_list_header_view_vertical_padding">20dp</dimen>
- <dimen name="widget_list_entry_bottom_margin">2dp</dimen>
+ <dimen name="widget_list_entry_spacing">2dp</dimen>
<dimen name="widget_preview_shadow_blur">0.5dp</dimen>
<dimen name="widget_preview_key_shadow_distance">1dp</dimen>