2
0
mirror of https://github.com/fork-maintainers/iceraven-browser synced 2024-11-15 18:12:54 +00:00

[fenix] Bug 1806798 - Make download filename scrollable.

Also add a max height for the file name, so the download button is always visible.
This commit is contained in:
mcarare 2023-01-31 15:00:19 +02:00 committed by mergify[bot]
parent da3e20d039
commit 0a843871b5
2 changed files with 4 additions and 0 deletions

View File

@ -6,6 +6,7 @@ package org.mozilla.fenix.downloads
import android.app.Activity import android.app.Activity
import android.app.Dialog import android.app.Dialog
import android.text.method.ScrollingMovementMethod
import android.view.Gravity import android.view.Gravity
import android.view.LayoutInflater import android.view.LayoutInflater
import android.view.View import android.view.View
@ -186,6 +187,7 @@ class FirstPartyDownloadDialog(
} }
dialog.filename.text = filename dialog.filename.text = filename
dialog.filename.movementMethod = ScrollingMovementMethod()
dialog.downloadButton.setOnClickListener { dialog.downloadButton.setOnClickListener {
positiveButtonAction() positiveButtonAction()

View File

@ -69,9 +69,11 @@
android:layout_marginStart="3dp" android:layout_marginStart="3dp"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:layout_toEndOf="@id/icon" android:layout_toEndOf="@id/icon"
android:maxHeight="160dp"
android:paddingStart="5dp" android:paddingStart="5dp"
android:paddingTop="4dp" android:paddingTop="4dp"
android:paddingEnd="5dp" android:paddingEnd="5dp"
android:scrollbars="vertical"
android:textColor="?android:attr/textColorPrimary" android:textColor="?android:attr/textColorPrimary"
tools:text="@tools:sample/lorem/random" tools:text="@tools:sample/lorem/random"
tools:textColor="#000000" /> tools:textColor="#000000" />