扫码附件设备,链接设备动画
BIN
app/src/main/res/drawable/connected_successfully.png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
app/src/main/res/drawable/device1.png
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
app/src/main/res/drawable/device2.png
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
app/src/main/res/drawable/device3.png
Normal file
|
After Width: | Height: | Size: 34 KiB |
7
app/src/main/res/drawable/device_frame_animation.xml
Normal file
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<animation-list xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:oneshot="false">
|
||||
<item android:drawable="@drawable/device1" android:duration="200" />
|
||||
<item android:drawable="@drawable/device2" android:duration="200" />
|
||||
<item android:drawable="@drawable/device3" android:duration="200" />
|
||||
</animation-list>
|
||||
16
app/src/main/res/drawable/device_wifi_animation.xml
Normal file
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<animation-list xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:oneshot="false">
|
||||
<item android:drawable="@drawable/img_add_dev_aini_1" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_add_dev_aini_2" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_add_dev_aini_3" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_add_dev_aini_2" android:duration="500"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_phone1" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_phone2" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_phone3" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_phone1" android:duration="500"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_wifi1" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_wifi2" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_wifi3" android:duration="200"/>
|
||||
<item android:drawable="@drawable/img_connect_anim_wifi1" android:duration="500"/>
|
||||
</animation-list>
|
||||
BIN
app/src/main/res/drawable/img_add_dev_aini_1.png
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
app/src/main/res/drawable/img_add_dev_aini_2.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
app/src/main/res/drawable/img_add_dev_aini_3.png
Normal file
|
After Width: | Height: | Size: 41 KiB |
BIN
app/src/main/res/drawable/img_connect_anim_phone1.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
app/src/main/res/drawable/img_connect_anim_phone2.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
app/src/main/res/drawable/img_connect_anim_phone3.png
Normal file
|
After Width: | Height: | Size: 27 KiB |
BIN
app/src/main/res/drawable/img_connect_anim_wifi1.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
app/src/main/res/drawable/img_connect_anim_wifi2.png
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
app/src/main/res/drawable/img_connect_anim_wifi3.png
Normal file
|
After Width: | Height: | Size: 18 KiB |
@@ -5,7 +5,7 @@
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:background="@color/message_bg"
|
||||
tools:context=".home.AddDeviceActivity">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
@@ -77,18 +77,19 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp">
|
||||
|
||||
<!--动画层 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/emptyState"
|
||||
android:id="@+id/animationContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:visibility="visible"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivEmpty"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="150dp"
|
||||
android:id="@+id/ivScanAnimation"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="260dp"
|
||||
android:src="@drawable/add_d" />
|
||||
|
||||
<TextView
|
||||
@@ -100,7 +101,7 @@
|
||||
android:textColor="@color/gray"
|
||||
android:textSize="14dp" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 初始隐藏 -->
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rvDevices"
|
||||
android:layout_width="match_parent"
|
||||
|
||||
@@ -131,6 +131,7 @@
|
||||
android:id="@+id/btnConfirm"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginBottom="40dp"
|
||||
android:background="@drawable/rounded_blue_bg"
|
||||
android:text="@string/next_step"
|
||||
android:textColor="@color/white"
|
||||
|
||||
100
app/src/main/res/layout/connect_device_activity.xml
Normal file
@@ -0,0 +1,100 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout 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:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
tools:context=".home.ConnectDeviceActivity">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/topBar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="56dp"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingHorizontal="16dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivBack"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@drawable/back" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/connect_device"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="16dp"
|
||||
android:textStyle="bold" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:layout_below="@id/topBar">
|
||||
<ImageView
|
||||
android:id="@+id/ivAnimation"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="333dp"
|
||||
android:layout_marginTop="48dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvStepText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="32dp"
|
||||
android:textSize="14dp"
|
||||
android:textColor="@color/gray" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvHint"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:textSize="14dp"
|
||||
android:textColor="@color/gray"
|
||||
android:gravity="center" />
|
||||
<TextView
|
||||
android:id="@+id/tvDeviceName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="5dp"
|
||||
android:textSize="14dp"
|
||||
android:textColor="@color/gray"
|
||||
android:gravity="center" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:gravity="center"
|
||||
android:id="@+id/successLayout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_centerInParent="true"
|
||||
android:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/successImage"
|
||||
android:layout_width="110dp"
|
||||
android:layout_height="110dp"
|
||||
android:src="@drawable/connected_successfully" />
|
||||
|
||||
<TextView
|
||||
android:layout_marginTop="20dp"
|
||||
android:id="@+id/successText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="连接成功"
|
||||
android:textSize="16dp" />
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
</RelativeLayout >
|
||||
@@ -75,7 +75,8 @@
|
||||
<android.widget.Button
|
||||
android:id="@+id/btnConfirm"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="48dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginBottom="40dp"
|
||||
android:background="@drawable/rounded_blue_bg"
|
||||
android:text="@string/complete"
|
||||
android:textColor="@color/white"
|
||||
|
||||
@@ -234,6 +234,7 @@
|
||||
<string name="connecting">连接中...</string>
|
||||
<string name="wifi_connection_failed">WiFi连接失败</string>
|
||||
<string name="wifi_connection_success">WiFi连接成功</string>
|
||||
<string name="connect_device">连接设备</string>
|
||||
|
||||
<!-- Dialog -->
|
||||
<string name="tip">提示</string>
|
||||
|
||||
@@ -207,6 +207,7 @@
|
||||
<string name="connecting">Connecting...</string>
|
||||
<string name="wifi_connection_failed">WiFi Connection failed</string>
|
||||
<string name="wifi_connection_success">WiFi Connected successfully</string>
|
||||
<string name="connect_device">Connect Device</string>
|
||||
|
||||
<!-- Dialog -->
|
||||
<string name="tip">Tip</string>
|
||||
|
||||