add popup window when connected; automatically open socket in background

This commit is contained in:
Kavish Devar
2024-11-29 23:35:46 +05:30
parent 58de49d1b1
commit 3e0de6f011
21 changed files with 1587 additions and 571 deletions

View File

@@ -0,0 +1,63 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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="wrap_content"
android:layout_margin="16.dp"
android:orientation="vertical"
android:background="@drawable/shape">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="end"
android:paddingBottom="48dp"
android:orientation="horizontal">
<TextView
android:id="@+id/name"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:fontFamily="@font/sf_pro"
android:gravity="center"
android:text="Kavish's AirPods Pro"
android:textColor="@color/white"
android:textSize="28sp"
app:layout_constraintTop_toTopOf="parent"
tools:ignore="HardcodedText" />
<ImageButton
android:id="@+id/close_button"
android:layout_width="28dp"
android:layout_height="28dp"
android:layout_marginTop="12dp"
android:layout_marginEnd="24dp"
android:background="@drawable/button_shape"
android:contentDescription="Close Button"
android:src="@drawable/close"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:ignore="HardcodedText" />
</androidx.constraintlayout.widget.ConstraintLayout>
<VideoView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/video"
android:contentDescription="AirPods"
android:src="@raw/connected"
tools:ignore="HardcodedText" />
<TextView
android:id="@+id/battery"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:fontFamily="@font/sf_pro"
android:gravity="center"
android:text=""
android:textColor="@color/white"
android:textSize="16sp"
tools:ignore="HardcodedText" />
</LinearLayout>