rss阅读记录单行显示,可滑动查看 (#4594)

This commit is contained in:
niuhb
2025-02-01 20:27:54 +08:00
committed by GitHub
parent cce7b9ee0a
commit 7aae910ef5
2 changed files with 26 additions and 11 deletions

View File

@@ -2,6 +2,7 @@ package io.legado.app.ui.rss.article
import android.content.Context
import android.os.Bundle
import android.text.method.ScrollingMovementMethod
import android.view.MenuItem
import android.view.View
import android.view.ViewGroup
@@ -76,6 +77,8 @@ class ReadRecordDialog : BaseDialogFragment(R.layout.dialog_recycler_view),
item: RssReadRecord,
payloads: MutableList<Any>
) {
binding.textTitle.movementMethod = ScrollingMovementMethod()
binding.textRecord.movementMethod = ScrollingMovementMethod()
binding.textTitle.text = item.title
binding.textRecord.text = item.record
}

View File

@@ -6,19 +6,31 @@
android:background="?android:attr/selectableItemBackground"
android:orientation="vertical">
<TextView
android:id="@+id/text_title"
android:text="@string/title"
<HorizontalScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textIsSelectable="true" />
android:layout_height="match_parent"
android:scrollbars="none">
<TextView
android:id="@+id/text_title"
android:text="@string/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:singleLine="true"
android:ellipsize="none" />
</HorizontalScrollView>
<TextView
android:id="@+id/text_record"
android:text="@string/read_record"
<HorizontalScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:autoLink="web"
android:textIsSelectable="true" />
android:layout_height="match_parent"
android:scrollbars="none">
<TextView
android:id="@+id/text_record"
android:text="@string/read_record"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:autoLink="web"
android:singleLine="true"
android:ellipsize="none" />
</HorizontalScrollView>
</LinearLayout>