From eeb86dfb88a441ac1230cb56ec91aabfe791d027 Mon Sep 17 00:00:00 2001 From: M66B Date: Fri, 8 Nov 2024 18:26:54 +0100 Subject: [PATCH] Tristate keyword checkbox --- .../main/java/eu/faircode/email/AdapterKeyword.java | 7 +++++-- app/src/main/res/drawable/ic_checked.xml | 10 ++++++++++ app/src/main/res/drawable/ic_indeterminate.xml | 13 +++++++++++++ app/src/main/res/drawable/ic_unchecked.xml | 10 ++++++++++ app/src/main/res/layout/item_keyword.xml | 1 + 5 files changed, 39 insertions(+), 2 deletions(-) create mode 100644 app/src/main/res/drawable/ic_checked.xml create mode 100644 app/src/main/res/drawable/ic_indeterminate.xml create mode 100644 app/src/main/res/drawable/ic_unchecked.xml diff --git a/app/src/main/java/eu/faircode/email/AdapterKeyword.java b/app/src/main/java/eu/faircode/email/AdapterKeyword.java index 6e66ce3a6a..e20f0f9c27 100644 --- a/app/src/main/java/eu/faircode/email/AdapterKeyword.java +++ b/app/src/main/java/eu/faircode/email/AdapterKeyword.java @@ -98,7 +98,10 @@ public class AdapterKeyword extends RecyclerView.Adapter + + diff --git a/app/src/main/res/drawable/ic_indeterminate.xml b/app/src/main/res/drawable/ic_indeterminate.xml new file mode 100644 index 0000000000..2990cbf111 --- /dev/null +++ b/app/src/main/res/drawable/ic_indeterminate.xml @@ -0,0 +1,13 @@ + + + + + + diff --git a/app/src/main/res/drawable/ic_unchecked.xml b/app/src/main/res/drawable/ic_unchecked.xml new file mode 100644 index 0000000000..2bc1e40020 --- /dev/null +++ b/app/src/main/res/drawable/ic_unchecked.xml @@ -0,0 +1,10 @@ + + + diff --git a/app/src/main/res/layout/item_keyword.xml b/app/src/main/res/layout/item_keyword.xml index 810fd1bf31..1c0a946046 100644 --- a/app/src/main/res/layout/item_keyword.xml +++ b/app/src/main/res/layout/item_keyword.xml @@ -15,6 +15,7 @@ android:id="@+id/cbKeyword" android:layout_width="0dp" android:layout_height="wrap_content" + android:paddingStart="6dp" android:text="Keyword" android:textAppearance="@style/TextAppearance.AppCompat.Medium" app:layout_constraintBottom_toBottomOf="parent"