diff options
author | Thomas <tschneider.ac@gmail.com> | 2023-09-20 18:00:59 +0200 |
---|---|---|
committer | Thomas <tschneider.ac@gmail.com> | 2023-09-20 18:00:59 +0200 |
commit | 69adba749391ad8365fe7c37d57214e4fbda28d0 (patch) | |
tree | 277f9bbea97ff5fc67f1d68e939766fabf6cbab3 | |
parent | ea636124fa6588903c3cb75784985fcde02d99aa (diff) |
some changes
3 files changed, 123 insertions, 88 deletions
diff --git a/app/src/main/java/app/fedilab/android/mastodon/ui/drawer/StatusAdapter.java b/app/src/main/java/app/fedilab/android/mastodon/ui/drawer/StatusAdapter.java index 05cfc9873..a351915f5 100644 --- a/app/src/main/java/app/fedilab/android/mastodon/ui/drawer/StatusAdapter.java +++ b/app/src/main/java/app/fedilab/android/mastodon/ui/drawer/StatusAdapter.java @@ -731,7 +731,6 @@ public class StatusAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder> } int truncate_toots_size = sharedpreferences.getInt(context.getString(R.string.SET_TRUNCATE_TOOTS_SIZE), 0); - if (extraFeatures) { if (displayQuote) { holder.binding.actionButtonQuote.setVisibility(View.VISIBLE); @@ -745,6 +744,10 @@ public class StatusAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder> holder.binding.statusAddCustomEmoji.setVisibility(View.GONE); holder.binding.statusEmoji.setVisibility(View.GONE); } + } else { + holder.binding.actionButtonQuote.setVisibility(View.GONE); + holder.binding.statusAddCustomEmoji.setVisibility(View.GONE); + holder.binding.statusEmoji.setVisibility(View.GONE); } if (statusToDeal.markdownShown) { diff --git a/app/src/main/res/layouts/mastodon/drawable/baseline_code_24.xml b/app/src/main/res/layouts/mastodon/drawable/baseline_code_24.xml index 450b9e61a..84b37a481 100644 --- a/app/src/main/res/layouts/mastodon/drawable/baseline_code_24.xml +++ b/app/src/main/res/layouts/mastodon/drawable/baseline_code_24.xml @@ -1,7 +1,7 @@ <vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" - android:tint="#FFFFFF" + android:tint="?attr/colorControlNormal" android:viewportWidth="24" android:viewportHeight="24"> <path diff --git a/app/src/main/res/layouts/mastodon/layout/drawer_status.xml b/app/src/main/res/layouts/mastodon/layout/drawer_status.xml index f61e869cf..f0c93d2a4 100644 --- a/app/src/main/res/layouts/mastodon/layout/drawer_status.xml +++ b/app/src/main/res/layouts/mastodon/layout/drawer_status.xml @@ -644,7 +644,6 @@ app:inactiveImage="@drawable/ic_round_reply_24" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintEnd_toStartOf="@+id/action_button_boost" app:layout_constraintTop_toTopOf="parent" app:primaryColor="@color/boost_icon" app:secondaryColor="@color/boost_icon" /> @@ -659,105 +658,112 @@ android:visibility="gone" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintStart_toEndOf="@+id/action_button_reply" + android:layout_marginEnd="10dp" tools:ignore="HardcodedText" tools:visibility="visible" /> - <com.varunest.sparkbutton.SparkButton - android:id="@+id/action_button_boost" - android:layout_width="48dp" - android:layout_height="48dp" - android:adjustViewBounds="true" - android:contentDescription="@string/reblog_add" - app:activeImage="@drawable/ic_round_repeat_active_24" - app:iconSize="28dp" - app:inactiveImage="@drawable/ic_round_repeat_24" - app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintEnd_toStartOf="@+id/action_button_favorite" - app:layout_constraintStart_toEndOf="@+id/action_button_reply_count" - app:layout_constraintTop_toTopOf="parent" - app:primaryColor="@color/boost_icon" - app:secondaryColor="@color/boost_icon" /> - - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/action_button_boost_count" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="bottom" - android:text="0" - android:textColor="?colorControlNormal" - app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintStart_toEndOf="@+id/action_button_boost" - android:visibility="gone" - tools:ignore="HardcodedText" - tools:visibility="visible" /> - - <com.varunest.sparkbutton.SparkButton - android:id="@+id/action_button_favorite" - android:layout_width="48dp" - android:layout_height="48dp" - android:layout_gravity="center" - android:adjustViewBounds="true" - android:contentDescription="@string/favourite_add" - app:activeImage="@drawable/ic_round_star_24" - app:animationSpeed="1.5" - app:inactiveImage="@drawable/ic_round_star_border_24" - app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintEnd_toStartOf="@+id/action_button_bookmark" - app:layout_constraintStart_toEndOf="@+id/action_button_boost_count" - app:layout_constraintTop_toTopOf="parent" - app:primaryColor="@color/marked_icon" - app:secondaryColor="@color/marked_icon" - sparkbutton:iconSize="28dp" /> - - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/action_button_favorite_count" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="bottom" - android:text="0" - android:textColor="?colorControlNormal" - android:visibility="gone" - app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintStart_toEndOf="@+id/action_button_favorite" - tools:ignore="HardcodedText" - tools:visibility="visible" /> - - - <com.varunest.sparkbutton.SparkButton - android:id="@+id/action_button_bookmark" - android:layout_width="48dp" - android:layout_height="48dp" - android:layout_gravity="center" - android:adjustViewBounds="true" - android:contentDescription="@string/bookmark_add" - app:activeImage="@drawable/ic_round_bookmark_24" - app:animationSpeed="1.5" - app:inactiveImage="@drawable/ic_round_bookmark_border_24" - app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintEnd_toStartOf="@+id/action_button_extra_container" - app:layout_constraintStart_toEndOf="@+id/action_button_favorite" - app:layout_constraintTop_toTopOf="parent" - app:primaryColor="@color/marked_icon" - app:secondaryColor="@color/marked_icon" - sparkbutton:iconSize="28dp" /> - <HorizontalScrollView android:id="@+id/action_button_extra_container" - android:layout_width="wrap_content" + android:layout_width="0dp" android:layout_height="wrap_content" android:fillViewport="true" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toStartOf="@+id/action_button_more" - app:layout_constraintStart_toEndOf="@+id/action_button_bookmark" + app:layout_constraintStart_toEndOf="@+id/action_button_reply_count" app:layout_constraintTop_toTopOf="parent"> - <androidx.appcompat.widget.LinearLayoutCompat + <androidx.constraintlayout.widget.ConstraintLayout android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:orientation="horizontal"> + android:layout_height="wrap_content"> + + <com.varunest.sparkbutton.SparkButton + android:id="@+id/action_button_boost" + android:layout_width="48dp" + android:layout_height="48dp" + android:adjustViewBounds="true" + android:contentDescription="@string/reblog_add" + app:activeImage="@drawable/ic_round_repeat_active_24" + app:iconSize="28dp" + app:inactiveImage="@drawable/ic_round_repeat_24" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/action_button_favorite" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintTop_toTopOf="parent" + app:primaryColor="@color/boost_icon" + app:secondaryColor="@color/boost_icon" /> + + <androidx.appcompat.widget.AppCompatTextView + android:id="@+id/action_button_boost_count" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="bottom" + android:text="0" + android:textColor="?colorControlNormal" + android:visibility="gone" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toEndOf="@+id/action_button_boost" + tools:ignore="HardcodedText" + tools:visibility="visible" /> + + <com.varunest.sparkbutton.SparkButton + android:id="@+id/action_button_favorite" + android:layout_width="48dp" + android:layout_height="48dp" + android:layout_gravity="center" + android:layout_marginStart="10dp" + android:adjustViewBounds="true" + android:contentDescription="@string/favourite_add" + app:activeImage="@drawable/ic_round_star_24" + app:animationSpeed="1.5" + app:inactiveImage="@drawable/ic_round_star_border_24" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/action_button_bookmark" + app:layout_constraintStart_toEndOf="@+id/action_button_boost_count" + app:layout_constraintTop_toTopOf="parent" + app:primaryColor="@color/marked_icon" + app:secondaryColor="@color/marked_icon" + sparkbutton:iconSize="28dp" /> + + <androidx.appcompat.widget.AppCompatTextView + android:id="@+id/action_button_favorite_count" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="bottom" + android:text="0" + android:textColor="?colorControlNormal" + android:visibility="gone" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toEndOf="@+id/action_button_favorite" + tools:ignore="HardcodedText" + tools:visibility="visible" /> + + + <com.varunest.sparkbutton.SparkButton + android:id="@+id/action_button_bookmark" + android:layout_width="48dp" + android:layout_height="48dp" + android:layout_gravity="center" + android:layout_marginStart="10dp" + android:adjustViewBounds="true" + android:contentDescription="@string/bookmark_add" + app:activeImage="@drawable/ic_round_bookmark_24" + app:animationSpeed="1.5" + app:inactiveImage="@drawable/ic_round_bookmark_border_24" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/action_button_quote" + app:layout_constraintStart_toEndOf="@+id/action_button_favorite" + app:layout_constraintTop_toTopOf="parent" + app:primaryColor="@color/marked_icon" + app:secondaryColor="@color/marked_icon" + sparkbutton:iconSize="28dp" /> <com.varunest.sparkbutton.SparkButton android:id="@+id/action_button_quote" + android:layout_marginStart="10dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/action_button_translate" + app:layout_constraintStart_toEndOf="@+id/action_button_bookmark" + app:layout_constraintTop_toTopOf="parent" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" @@ -770,6 +776,11 @@ <com.varunest.sparkbutton.SparkButton android:id="@+id/action_button_translate" + android:layout_marginStart="10dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/action_button_maths" + app:layout_constraintStart_toEndOf="@+id/action_button_quote" + app:layout_constraintTop_toTopOf="parent" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" @@ -782,6 +793,11 @@ <com.varunest.sparkbutton.SparkButton android:id="@+id/action_button_maths" + android:layout_marginStart="10dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/action_button_markdown" + app:layout_constraintStart_toEndOf="@+id/action_button_translate" + app:layout_constraintTop_toTopOf="parent" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" @@ -794,6 +810,11 @@ <com.varunest.sparkbutton.SparkButton android:id="@+id/action_button_markdown" + android:layout_marginStart="10dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/status_add_custom_emoji" + app:layout_constraintStart_toEndOf="@+id/action_button_maths" + app:layout_constraintTop_toTopOf="parent" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" @@ -806,6 +827,11 @@ <com.varunest.sparkbutton.SparkButton android:id="@+id/status_add_custom_emoji" + android:layout_marginStart="10dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toStartOf="@+id/status_emoji" + app:layout_constraintStart_toEndOf="@+id/action_button_markdown" + app:layout_constraintTop_toTopOf="parent" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" @@ -818,6 +844,11 @@ <com.varunest.sparkbutton.SparkButton android:id="@+id/status_emoji" + android:layout_marginStart="10dp" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintStart_toEndOf="@+id/status_add_custom_emoji" + app:layout_constraintTop_toTopOf="parent" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" @@ -828,13 +859,14 @@ app:inactiveImage="@drawable/ic_baseline_add_reaction_24" sparkbutton:iconSize="28dp" /> - </androidx.appcompat.widget.LinearLayoutCompat> + </androidx.constraintlayout.widget.ConstraintLayout> </HorizontalScrollView> <com.varunest.sparkbutton.SparkButton android:id="@+id/action_button_more" + android:layout_marginStart="10dp" android:layout_width="48dp" android:layout_height="48dp" android:layout_gravity="center" |