Commit 6f351235 authored by Thomas's avatar Thomas
Browse files

more place for icons

parent 90cc5b0e
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -864,12 +864,14 @@ public class StatusAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
        }
        //Button sizes depending of the defined scale
        float normalSize = Helper.convertDpToPixel(28, context);
        float normalSize2 = Helper.convertDpToPixel(24, context);
        holder.binding.actionButtonReply.getLayoutParams().width = (int) (normalSize * scaleIcon);
        holder.binding.actionButtonReply.getLayoutParams().height = (int) (normalSize * scaleIcon);
        holder.binding.actionButtonReply.requestLayout();
        holder.binding.actionButtonBoost.setImageSize((int) (normalSize * scaleIcon));
        holder.binding.actionButtonFavorite.setImageSize((int) (normalSize * scaleIcon));
        holder.binding.actionButtonBookmark.setImageSize((int) (normalSize * scaleIcon));
        holder.binding.actionButtonBookmark.setImageSize((int) (normalSize2 * scaleIcon));

        holder.binding.statusAddCustomEmoji.getLayoutParams().width = (int) (normalSize * scaleIcon);
        holder.binding.statusAddCustomEmoji.getLayoutParams().height = (int) (normalSize * scaleIcon);
        holder.binding.statusAddCustomEmoji.requestLayout();
@@ -1075,6 +1077,8 @@ public class StatusAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
                    holder.binding.toggleTruncate.setVisibility(View.GONE);
                }
            });
        } else {
            holder.binding.toggleTruncate.setVisibility(View.GONE);
        }
        if (statusToDeal.translationContent != null) {
            holder.binding.containerTrans.setVisibility(View.VISIBLE);
+59 −37
Original line number Diff line number Diff line
@@ -314,7 +314,7 @@
            app:cardCornerRadius="8dp"
            app:cardElevation="0dp"
            app:strokeWidth="1dp"
            tools:visibility="visible">
            >

            <androidx.appcompat.widget.LinearLayoutCompat
                android:layout_width="match_parent"
@@ -569,26 +569,35 @@
            layout="@layout/layout_reactions"
            android:visibility="gone" />

        <androidx.appcompat.widget.LinearLayoutCompat
        <androidx.constraintlayout.widget.ConstraintLayout
            android:id="@+id/action_buttons"
            android:layout_width="match_parent"
            android:layout_height="28dp"
            android:layout_height="48dp"
            android:layout_marginStart="48dp"
            android:layout_marginTop="6dp"
            android:layout_marginEnd="6dp"
            android:clipChildren="false"
            android:clipToPadding="false">

            <androidx.appcompat.widget.LinearLayoutCompat
                android:id="@+id/action_button_reply_container"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:orientation="horizontal"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintStart_toStartOf="parent"
                app:layout_constraintTop_toTopOf="parent">

                <androidx.appcompat.widget.AppCompatImageView
                    android:id="@+id/action_button_reply"
                    android:layout_width="28dp"
                    android:layout_height="28dp"
                android:contentDescription="@string/reply"
                    android:layout_gravity="center"
                    android:layout_marginStart="6dp"
                    android:adjustViewBounds="true"
                    android:clickable="true"
                    android:contentDescription="@string/reply"
                    android:focusable="true"
                android:layout_marginStart="6dp"
                    app:srcCompat="@drawable/ic_reply" />

                <androidx.appcompat.widget.AppCompatTextView
@@ -601,9 +610,14 @@
                    android:textSize="12sp"
                    android:visibility="gone"
                    tools:ignore="HardcodedText" />
            </androidx.appcompat.widget.LinearLayoutCompat>

            <com.varunest.sparkbutton.SparkButton
                android:id="@+id/action_button_boost"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toStartOf="@+id/action_button_favorite"
                app:layout_constraintStart_toEndOf="@+id/action_button_reply_container"
                app:layout_constraintTop_toTopOf="parent"
                android:layout_width="28dp"
                android:layout_height="28dp"
                android:layout_marginStart="12dp"
@@ -619,6 +633,10 @@

            <com.varunest.sparkbutton.SparkButton
                android:id="@+id/action_button_favorite"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toStartOf="@+id/action_button_bookmark"
                app:layout_constraintStart_toEndOf="@+id/action_button_boost"
                app:layout_constraintTop_toTopOf="parent"
                android:layout_width="28dp"
                android:layout_height="28dp"
                android:layout_gravity="center"
@@ -635,13 +653,16 @@

            <com.varunest.sparkbutton.SparkButton
                android:id="@+id/action_button_bookmark"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toStartOf="@+id/status_add_custom_emoji"
                app:layout_constraintStart_toEndOf="@+id/action_button_favorite"
                app:layout_constraintTop_toTopOf="parent"
                android:layout_width="28dp"
                android:layout_height="28dp"
                android:layout_gravity="center"
                android:layout_marginStart="12dp"
                android:layout_marginTop="2dp"

                android:adjustViewBounds="true"
                android:visibility="gone"
                android:contentDescription="@string/bookmark_add"
                app:sparkbutton_activeImage="@drawable/ic_baseline_bookmark_24"
                app:sparkbutton_animationSpeed="1.5"
@@ -651,13 +672,12 @@
                app:sparkbutton_secondaryColor="@color/marked_icon" />


            <View
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="1" />

            <androidx.appcompat.widget.AppCompatImageView
                android:id="@+id/status_add_custom_emoji"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toStartOf="@+id/status_emoji"
                app:layout_constraintStart_toEndOf="@+id/action_button_bookmark"
                app:layout_constraintTop_toTopOf="parent"
                android:layout_width="28dp"
                android:layout_height="28dp"
                android:contentDescription="@string/add_reaction"
@@ -672,6 +692,10 @@

            <androidx.appcompat.widget.AppCompatImageView
                android:id="@+id/status_emoji"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toStartOf="@+id/action_button_more"
                app:layout_constraintStart_toEndOf="@+id/status_add_custom_emoji"
                app:layout_constraintTop_toTopOf="parent"
                android:layout_width="28dp"
                android:layout_height="28dp"
                android:layout_marginStart="6dp"
@@ -685,23 +709,21 @@
                android:visibility="gone"
                tools:visibility="visible" />

            <View
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="1" />

            <androidx.appcompat.widget.AppCompatImageView
                android:id="@+id/action_button_more"
                android:layout_gravity="center|end"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toEndOf="parent"
                android:contentDescription="@string/display_options"
                android:layout_width="28dp"
                android:layout_height="28dp"
                android:layout_gravity="center"
                app:layout_constraintTop_toTopOf="parent"
                android:clickable="true"
                android:adjustViewBounds="true"
                android:focusable="true"
                app:srcCompat="@drawable/ic_more_horiz" />

        </androidx.appcompat.widget.LinearLayoutCompat>
        </androidx.constraintlayout.widget.ConstraintLayout>

        <include
            android:id="@+id/layout_fetch_more"