90 lines
3.1 KiB
XML
90 lines
3.1 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
|
<!-- OTA 更新弹窗(全屏覆盖,阻断用户操作) -->
|
|||
|
|
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|||
|
|
android:layout_width="match_parent"
|
|||
|
|
android:layout_height="match_parent"
|
|||
|
|
android:background="#E6000000"
|
|||
|
|
android:clickable="true"
|
|||
|
|
android:focusable="true">
|
|||
|
|
|
|||
|
|
<LinearLayout
|
|||
|
|
android:layout_width="match_parent"
|
|||
|
|
android:layout_height="match_parent"
|
|||
|
|
android:gravity="center"
|
|||
|
|
android:orientation="vertical"
|
|||
|
|
android:padding="24dp">
|
|||
|
|
|
|||
|
|
<!-- 图标 -->
|
|||
|
|
<TextView
|
|||
|
|
android:id="@+id/tvIcon"
|
|||
|
|
android:layout_width="wrap_content"
|
|||
|
|
android:layout_height="wrap_content"
|
|||
|
|
android:fontFamily="@font/iconfont"
|
|||
|
|
android:text=""
|
|||
|
|
android:textColor="@android:color/white"
|
|||
|
|
android:textSize="40sp" />
|
|||
|
|
|
|||
|
|
<!-- 标题 -->
|
|||
|
|
<TextView
|
|||
|
|
android:id="@+id/tvTitle"
|
|||
|
|
android:layout_width="wrap_content"
|
|||
|
|
android:layout_height="wrap_content"
|
|||
|
|
android:layout_marginTop="12dp"
|
|||
|
|
android:text="发现新版本"
|
|||
|
|
android:textColor="@android:color/white"
|
|||
|
|
android:textSize="18sp"
|
|||
|
|
android:textStyle="bold" />
|
|||
|
|
|
|||
|
|
<!-- 描述(下载中显示"请勿关机!正在升级系统...") -->
|
|||
|
|
<TextView
|
|||
|
|
android:id="@+id/tvDesc"
|
|||
|
|
android:layout_width="wrap_content"
|
|||
|
|
android:layout_height="wrap_content"
|
|||
|
|
android:layout_marginTop="4dp"
|
|||
|
|
android:textColor="#AAFFFFFF"
|
|||
|
|
android:textSize="12sp"
|
|||
|
|
android:visibility="gone" />
|
|||
|
|
|
|||
|
|
<!-- 进度条(下载中显示) -->
|
|||
|
|
<FrameLayout
|
|||
|
|
android:id="@+id/progressContainer"
|
|||
|
|
android:layout_width="match_parent"
|
|||
|
|
android:layout_height="8dp"
|
|||
|
|
android:layout_marginTop="16dp"
|
|||
|
|
android:background="#33FFFFFF"
|
|||
|
|
android:visibility="gone">
|
|||
|
|
|
|||
|
|
<View
|
|||
|
|
android:id="@+id/progressBar"
|
|||
|
|
android:layout_width="0dp"
|
|||
|
|
android:layout_height="match_parent"
|
|||
|
|
android:background="#4CAF50" />
|
|||
|
|
</FrameLayout>
|
|||
|
|
|
|||
|
|
<!-- 进度文字 -->
|
|||
|
|
<TextView
|
|||
|
|
android:id="@+id/tvProgress"
|
|||
|
|
android:layout_width="wrap_content"
|
|||
|
|
android:layout_height="wrap_content"
|
|||
|
|
android:layout_marginTop="4dp"
|
|||
|
|
android:textColor="#AAFFFFFF"
|
|||
|
|
android:textSize="12sp"
|
|||
|
|
android:visibility="gone" />
|
|||
|
|
|
|||
|
|
<!-- 按钮(立即更新 / 重新下载) -->
|
|||
|
|
<TextView
|
|||
|
|
android:id="@+id/btnAction"
|
|||
|
|
android:layout_width="wrap_content"
|
|||
|
|
android:layout_height="wrap_content"
|
|||
|
|
android:layout_marginTop="16dp"
|
|||
|
|
android:background="@drawable/bg_btn_primary"
|
|||
|
|
android:paddingHorizontal="24dp"
|
|||
|
|
android:paddingVertical="8dp"
|
|||
|
|
android:text="立即更新"
|
|||
|
|
android:textColor="@android:color/white"
|
|||
|
|
android:textSize="14sp" />
|
|||
|
|
|
|||
|
|
</LinearLayout>
|
|||
|
|
|
|||
|
|
</FrameLayout>
|