Kkunfei优化
52ed61af创建于 2023年4月18日历史提交
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <io.legado.app.ui.widget.TitleBar
        android:id="@+id/title_bar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:contentLayout="@layout/view_search"
        app:contentInsetRight="24dp"
        app:layout_constraintTop_toTopOf="parent" />

    <io.legado.app.ui.widget.anima.RefreshProgressBar
        android:id="@+id/refresh_progress_bar"
        android:layout_width="match_parent"
        android:layout_height="2dp"
        app:layout_constraintTop_toBottomOf="@id/title_bar" />

    <io.legado.app.ui.widget.recycler.scroller.FastScrollRecyclerView
        android:id="@+id/recycler_view"
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:overScrollMode="never"
        app:layout_constraintBottom_toTopOf="@+id/ll_search_base_info"
        app:layout_constraintTop_toBottomOf="@id/refresh_progress_bar"
        tools:ignore="SpeakableTextPresentCheck" />

    <LinearLayout
        android:id="@+id/ll_search_base_info"
        android:layout_width="match_parent"
        android:layout_height="36dp"
        android:background="@color/background"
        android:elevation="5dp"
        android:gravity="center_vertical"
        android:orientation="horizontal"
        android:paddingLeft="10dp"
        android:paddingRight="10dp"
        app:layout_constraintBottom_toBottomOf="parent">

        <TextView
            android:id="@+id/tv_current_search_info"
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:background="?android:attr/selectableItemBackgroundBorderless"
            android:ellipsize="middle"
            android:gravity="center_vertical"
            android:paddingLeft="10dp"
            android:paddingRight="10dp"
            android:singleLine="true"
            android:textColor="@color/primaryText"
            android:textSize="12sp" />

        <Space
            android:layout_width="20dp"
            android:layout_height="1dp" />

        <androidx.appcompat.widget.AppCompatImageView
            android:id="@+id/iv_search_content_top"
            android:layout_width="36dp"
            android:layout_height="match_parent"
            android:background="?android:attr/selectableItemBackgroundBorderless"
            android:contentDescription="@string/go_to_top"
            android:src="@drawable/ic_arrow_drop_up"
            android:tooltipText="@string/go_to_top"
            app:tint="@color/primaryText"
            tools:ignore="UnusedAttribute" />

        <androidx.appcompat.widget.AppCompatImageView
            android:id="@+id/iv_search_content_bottom"
            android:layout_width="36dp"
            android:layout_height="match_parent"
            android:background="?android:attr/selectableItemBackgroundBorderless"
            android:contentDescription="@string/go_to_bottom"
            android:src="@drawable/ic_arrow_drop_down"
            android:tooltipText="@string/go_to_bottom"
            app:tint="@color/primaryText"
            tools:ignore="UnusedAttribute" />
    </LinearLayout>

    <com.google.android.material.floatingactionbutton.FloatingActionButton
        android:id="@+id/fb_stop"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_margin="16dp"
        android:src="@drawable/ic_stop_black_24dp"
        android:visibility="invisible"
        android:contentDescription="@string/stop"
        app:fabSize="mini"
        app:layout_constraintBottom_toTopOf="@+id/ll_search_base_info"
        app:layout_constraintRight_toRightOf="parent" />

</androidx.constraintlayout.widget.ConstraintLayout>