diff --git a/app/src/main/java/io/legado/app/ui/main/explore/ExploreAdapter.kt b/app/src/main/java/io/legado/app/ui/main/explore/ExploreAdapter.kt index 205cf4e2c..c0d19851f 100644 --- a/app/src/main/java/io/legado/app/ui/main/explore/ExploreAdapter.kt +++ b/app/src/main/java/io/legado/app/ui/main/explore/ExploreAdapter.kt @@ -73,6 +73,7 @@ class ExploreAdapter(context: Context, private val scope: CoroutineScope, val ca kindList.map { kind -> val tv = LayoutInflater.from(context) .inflate(R.layout.item_text, gl_child, false) + gl_child.addView(tv) tv.text_view.text = kind.title tv.text_view.onClick { kind.url?.let { kindUrl -> @@ -83,7 +84,6 @@ class ExploreAdapter(context: Context, private val scope: CoroutineScope, val ca ) } } - gl_child.addView(tv) } } }.onFinally { diff --git a/app/src/main/res/layout/item_text.xml b/app/src/main/res/layout/item_text.xml index 87687a713..331bd8a2c 100644 --- a/app/src/main/res/layout/item_text.xml +++ b/app/src/main/res/layout/item_text.xml @@ -6,12 +6,10 @@ android:layout_height="wrap_content" android:layout_margin="3dp" android:background="@drawable/selector_fillet_btn_bg" - android:clickable="true" android:ellipsize="end" - android:focusable="true" android:gravity="center" android:padding="5dp" - android:singleLine="true" + android:maxLines="1" android:textColor="@color/tv_text_default" android:textSize="14sp" tools:ignore="UnusedAttribute" />