summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
authorAndrew Lee <anwlee@google.com>2015-09-01 17:59:10 -0700
committerAndrew Lee <anwlee@google.com>2015-09-01 18:22:49 -0700
commitab90a18e2f05c7ae4158b770a9fbe9cbe4544597 (patch)
tree8582caa28ef33d2ed89b090ccf9357c015da26ac /res
parent0599e880630892becf1a1991e6712e0e6d9df3c8 (diff)
Genericize promo card.
+ Make ViewHolder generic to generic to promo cards with customized text or graphic layouts, as long as they implement two actions, now designated the primary and secondary action views. This resuses code which is logically similar between promo cards, and hopefully doesn't bite us back in the future if there is a divergence in promo card structure. + Make the GroupingListAdapter slightly "safer". Bug: 23422274 Change-Id: I60bced4dbc61fec2e225a1cae9726ac40ed679a5
Diffstat (limited to 'res')
-rw-r--r--res/layout/voicemail_promo_card.xml8
1 files changed, 4 insertions, 4 deletions
diff --git a/res/layout/voicemail_promo_card.xml b/res/layout/voicemail_promo_card.xml
index 103fa30b3..891f09693 100644
--- a/res/layout/voicemail_promo_card.xml
+++ b/res/layout/voicemail_promo_card.xml
@@ -79,20 +79,20 @@
android:gravity="end">
<TextView
- android:id="@+id/settings_action"
+ android:id="@+id/secondary_action"
style="@style/PromoCardActionStyle"
android:background="?android:attr/selectableItemBackground"
android:text="@string/visual_voicemail_settings"
android:nextFocusLeft="@+id/promo_card"
- android:nextFocusRight="@+id/ok_action"
+ android:nextFocusRight="@+id/primary_action"
android:paddingEnd="@dimen/promo_card_action_between_padding"/>
<TextView
- android:id="@+id/ok_action"
+ android:id="@+id/primary_action"
style="@style/PromoCardActionStyle"
android:background="?android:attr/selectableItemBackground"
android:text="@android:string/ok"
- android:nextFocusLeft="@+id/settings_action"
+ android:nextFocusLeft="@+id/secondary_action"
android:nextFocusRight="@+id/promo_card"/>
</LinearLayout>
</LinearLayout>