Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1c6f7596 authored by Matt Casey's avatar Matt Casey Committed by Android (Google) Code Review
Browse files

Merge "Minor Copy/Paste overlay UI edits" into tm-dev

parents 2e92c6b7 9c6e8f9c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -44,10 +44,10 @@
        android:layout_height="0dp"
        android:layout_marginTop="8dp"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintLeft_toLeftOf="parent"
        app:layout_constraintRight_toRightOf="parent"
        app:layout_constraintStart_toStartOf="@+id/copy_button"
        app:layout_constraintEnd_toEndOf="@id/share"
        app:layout_constraintTop_toBottomOf="@+id/attribution">

        <EditText
+3 −1
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@
  -->
<FrameLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:alpha="0"
    android:layout_width="match_parent"
@@ -118,7 +119,8 @@
                      android:autoSizeTextType="uniform"
                      android:autoSizeMinTextSize="10sp"
                      android:autoSizeMaxTextSize="200sp"
                      android:textColor="?android:attr/textColorPrimary"
                      android:textColor="?attr/overlayButtonTextColor"
                      android:background="?androidprv:attr/colorAccentSecondary"
                      android:layout_width="@dimen/clipboard_preview_size"
                      android:layout_height="@dimen/clipboard_preview_size"/>
            <ImageView
+7 −0
Original line number Diff line number Diff line
@@ -190,6 +190,13 @@ public class ClipboardOverlayController {
            }
        });

        mTextPreview.getViewTreeObserver().addOnPreDrawListener(() -> {
            int availableHeight = mTextPreview.getHeight()
                    - (mTextPreview.getPaddingTop() + mTextPreview.getPaddingBottom());
            mTextPreview.setMaxLines(availableHeight / mTextPreview.getLineHeight());
            return true;
        });

        mDismissButton.setOnClickListener(view -> animateOut());

        mEditChip.setIcon(Icon.createWithResource(mContext, R.drawable.ic_screenshot_edit), true);