pandorapan/common/src/main/res/layout/view_refresh_default.xml

108 lines
4.2 KiB
XML
Raw Normal View History

2022-07-18 15:31:45 +08:00
<?xml version="1.0" encoding="utf-8"?>
2022-08-17 09:29:24 +08:00
<com.scwang.smartrefresh.layout.SmartRefreshLayout xmlns:android="http://schemas.android.com/apk/res/android"
2022-07-18 15:31:45 +08:00
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/refreshLayout"
android:layout_width="match_parent"
2022-08-17 09:29:24 +08:00
android:layout_height="match_parent">
2022-07-18 15:31:45 +08:00
2022-09-02 16:30:16 +08:00
<com.yunbao.common.views.weight.ClassicsHeaderNew
2022-07-18 15:31:45 +08:00
android:id="@+id/header"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:srlTextFailed="@string/refresh_header_failed"
app:srlTextFinish="@string/refresh_header_finish"
app:srlTextLoading="@string/refresh_header_loading"
app:srlTextPulling="@string/refresh_header_pulling"
app:srlTextRefreshing="@string/refresh_header_refreshing"
app:srlTextRelease="@string/refresh_header_release"
2022-08-17 09:29:24 +08:00
app:srlTextUpdate="@string/refresh_header_update" />
2022-07-18 15:31:45 +08:00
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
2022-08-17 09:29:24 +08:00
android:overScrollMode="never" />
2022-07-18 15:31:45 +08:00
<FrameLayout
android:id="@+id/no_data_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
2022-08-17 09:29:24 +08:00
android:visibility="invisible">
2022-07-18 15:31:45 +08:00
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginBottom="8dp"
android:text="@string/no_data"
android:textColor="@color/gray1"
2022-08-17 09:29:24 +08:00
android:textSize="14sp" />
2022-07-18 15:31:45 +08:00
</FrameLayout>
<LinearLayout
android:id="@+id/load_failure"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:gravity="center_horizontal"
android:orientation="vertical"
android:translationY="-60dp"
2022-08-17 09:29:24 +08:00
android:visibility="invisible">
2022-07-18 15:31:45 +08:00
<ImageView
android:layout_width="120dp"
android:layout_height="74dp"
android:scaleType="fitXY"
2022-08-17 09:29:24 +08:00
android:src="@mipmap/bg_load_failure" />
2022-07-18 15:31:45 +08:00
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
2022-08-17 09:29:24 +08:00
android:layout_marginBottom="8dp"
2022-07-18 15:31:45 +08:00
android:text="@string/load_failure"
android:textColor="@color/textColor"
2022-08-17 09:29:24 +08:00
android:textSize="14sp" />
2022-07-18 15:31:45 +08:00
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/load_failure_2"
android:textColor="@color/gray1"
2022-08-17 09:29:24 +08:00
android:textSize="14sp" />
2022-07-18 15:31:45 +08:00
<TextView
android:id="@+id/btn_reload"
android:layout_width="60dp"
android:layout_height="28dp"
android:layout_marginTop="8dp"
android:background="@drawable/btn_reload"
android:gravity="center"
android:text="@string/reload"
android:textColor="@color/white"
2022-08-17 09:29:24 +08:00
android:textSize="14sp" />
2022-07-18 15:31:45 +08:00
</LinearLayout>
</FrameLayout>
<com.scwang.smartrefresh.layout.footer.ClassicsFooter
android:id="@+id/footer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2022-08-17 09:29:24 +08:00
android:visibility="gone"
2022-07-18 15:31:45 +08:00
app:srlTextFailed="@string/refresh_footer_failed"
app:srlTextFinish="@string/refresh_footer_finish"
app:srlTextLoading="@string/refresh_footer_loading"
app:srlTextNothing="@string/refresh_footer_nothing"
app:srlTextPulling="@string/refresh_footer_pulling"
app:srlTextRefreshing="@string/refresh_footer_refreshing"
2022-08-17 09:29:24 +08:00
app:srlTextRelease="@string/refresh_footer_release" />
2022-07-18 15:31:45 +08:00
</com.scwang.smartrefresh.layout.SmartRefreshLayout>