From f6a8cd93da4adb94f7c4d046503a45623bb8a08d Mon Sep 17 00:00:00 2001 From: Niels Andriesse Date: Thu, 12 Mar 2020 15:57:53 +1100 Subject: [PATCH] Implement new conversation button redesign --- res/drawable/ic_group.xml | 18 ++ res/drawable/ic_message.xml | 12 + res/drawable/ic_plus.xml | 18 ++ .../new_conversation_button_background.xml | 5 +- .../new_conversation_button_foreground.xml | 7 - res/layout/activity_home.xml | 55 +--- res/values/colors.xml | 1 + res/values/dimens.xml | 3 +- .../loki/redesign/activities/HomeActivity.kt | 16 +- .../redesign/utilities/PointFUtilities.kt | 32 +++ .../redesign/utilities/ViewGroupUtilities.kt | 9 + .../loki/redesign/utilities/ViewUtilities.kt | 16 ++ .../views/NewConversationButtonSetView.kt | 272 ++++++++++++++++++ 13 files changed, 393 insertions(+), 71 deletions(-) create mode 100644 res/drawable/ic_group.xml create mode 100644 res/drawable/ic_message.xml create mode 100644 res/drawable/ic_plus.xml delete mode 100644 res/drawable/new_conversation_button_foreground.xml create mode 100644 src/org/thoughtcrime/securesms/loki/redesign/utilities/PointFUtilities.kt create mode 100644 src/org/thoughtcrime/securesms/loki/redesign/utilities/ViewGroupUtilities.kt create mode 100644 src/org/thoughtcrime/securesms/loki/redesign/utilities/ViewUtilities.kt create mode 100644 src/org/thoughtcrime/securesms/loki/redesign/views/NewConversationButtonSetView.kt diff --git a/res/drawable/ic_group.xml b/res/drawable/ic_group.xml new file mode 100644 index 0000000000..2b77ad4c47 --- /dev/null +++ b/res/drawable/ic_group.xml @@ -0,0 +1,18 @@ + + + + diff --git a/res/drawable/ic_message.xml b/res/drawable/ic_message.xml new file mode 100644 index 0000000000..77b88ec345 --- /dev/null +++ b/res/drawable/ic_message.xml @@ -0,0 +1,12 @@ + + + diff --git a/res/drawable/ic_plus.xml b/res/drawable/ic_plus.xml new file mode 100644 index 0000000000..e57a46a646 --- /dev/null +++ b/res/drawable/ic_plus.xml @@ -0,0 +1,18 @@ + + + + diff --git a/res/drawable/new_conversation_button_background.xml b/res/drawable/new_conversation_button_background.xml index be48173893..4de519558a 100644 --- a/res/drawable/new_conversation_button_background.xml +++ b/res/drawable/new_conversation_button_background.xml @@ -1,7 +1,4 @@ - - - \ No newline at end of file + android:shape="oval" /> \ No newline at end of file diff --git a/res/drawable/new_conversation_button_foreground.xml b/res/drawable/new_conversation_button_foreground.xml deleted file mode 100644 index 44bb8f9675..0000000000 --- a/res/drawable/new_conversation_button_foreground.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - \ No newline at end of file diff --git a/res/layout/activity_home.xml b/res/layout/activity_home.xml index 28e927d94d..df7e4be5c2 100644 --- a/res/layout/activity_home.xml +++ b/res/layout/activity_home.xml @@ -40,28 +40,6 @@ android:layout_centerVertical="true" android:layout_marginLeft="64dp" /> - - - - - - - - @@ -80,36 +58,13 @@ android:layout_width="match_parent" android:layout_height="match_parent" /> - - - - - - -