<?xml version="1.0" encoding="utf-8"?>
<com.qmuiteam.qmui.widget.QMUIWindowInsetLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@mipmap/down_decoration">

    <!--    <com.qmuiteam.qmui.widget.QMUITopBar-->
    <!--        android:id="@+id/topbar"-->
    <!--        android:layout_width="match_parent"-->
    <!--        android:layout_height="?attr/qmui_topbar_height"-->
    <!--        android:layout_marginTop="@dimen/dp_20"-->
    <!--        android:background="@color/trans" />-->

    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="@dimen/dp_50"
        android:layout_marginTop="@dimen/dp_30"
        android:background="@color/trans">

        <com.qmuiteam.qmui.alpha.QMUIAlphaImageButton
            android:id="@+id/btn_back"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_centerVertical="true"
            android:layout_marginLeft="@dimen/dp_15"
            android:src="@drawable/qmui_icon_topbar_back" />

        <TextView
            android:id="@+id/tv_title"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_centerInParent="true"
            android:text="數據下載"
            android:textColor="@color/theme_white_color"
            android:textSize="@dimen/sp_16" />

        <com.qmuiteam.qmui.alpha.QMUIAlphaImageButton
            android:id="@+id/btn_refresh"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentRight="true"
            android:layout_centerVertical="true"
            android:layout_marginRight="@dimen/dp_15"
            android:src="@drawable/icon_refresh" />
    </RelativeLayout>

    <androidx.constraintlayout.widget.ConstraintLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_marginTop="@dimen/dp_80"
        android:orientation="vertical">

        <FrameLayout
            android:id="@+id/frame_top"
            android:layout_width="match_parent"
            android:layout_height="0dp"
            app:layout_constraintBottom_toTopOf="@id/recycle_download"
            app:layout_constraintTop_toTopOf="parent"
            app:layout_constraintVertical_weight="1">

            <ImageView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_gravity="center"
                android:src="@mipmap/down_cloud" />

            <TextView
                android:id="@+id/tv_progress"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_gravity="center"
                android:layout_marginTop="@dimen/dp_12"
                android:text="100%"
                android:textColor="#13B7F5"
                android:textSize="@dimen/sp_24" />
        </FrameLayout>

        <com.gingersoft.gsa.cloud.ui.view.WaveView
            android:id="@+id/wave_download"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            app:behindWaveColor="#ccc"
            app:frontWaveColor="#ffffff"
            app:waveShape="square" />

        <androidx.recyclerview.widget.RecyclerView
            android:id="@+id/recycle_download"
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:fadeScrollbars="false"
            android:listSelector="@color/theme_background_color"
            android:paddingTop="@dimen/dp_50"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintTop_toBottomOf="@id/frame_top"
            app:layout_constraintVertical_weight="1" />


    </androidx.constraintlayout.widget.ConstraintLayout>

</com.qmuiteam.qmui.widget.QMUIWindowInsetLayout>