From 0f9b2a7df8c5d2a80d8dc7aeee789f3f0d4413b4 Mon Sep 17 00:00:00 2001 From: nikk gitanes Date: Mon, 6 Jun 2022 02:23:02 +0300 Subject: [PATCH] make module card clickable and highlight when focused --- app/src/main/res/layout/item_module_md2.xml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/src/main/res/layout/item_module_md2.xml b/app/src/main/res/layout/item_module_md2.xml index 4ebd9e8bc..f9a93ca63 100644 --- a/app/src/main/res/layout/item_module_md2.xml +++ b/app/src/main/res/layout/item_module_md2.xml @@ -28,7 +28,10 @@ isEnabled="@{!item.removed && item.enabled && !item.showNotice}" android:layout_width="match_parent" android:layout_height="wrap_content" + android:clickable="@{!item.removed && item.enabled && !item.showNotice}" + android:focusable="@{!item.removed && item.enabled && !item.showNotice}" android:nextFocusRight="@id/module_indicator" + android:onClick="@{() -> item.setEnabled(!item.enabled)}" app:cardBackgroundColor="@color/color_card_background_color_selector" tools:isEnabled="false" tools:layout_gravity="center"