Proximity sensor trigger

This commit is contained in:
2025-11-02 19:10:05 +01:00
parent e8e763210b
commit 3497d7b8ea
6 changed files with 316 additions and 0 deletions

View File

@@ -0,0 +1,90 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_margin="@dimen/default_margin">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/proximity"
android:textAppearance="@style/TextAppearance.AppCompat.Headline"
android:layout_marginBottom="@dimen/default_margin" />
<TableLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:shrinkColumns="1"
android:stretchColumns="1" >
<TableRow>
<TextView
android:layout_height="wrap_content"
android:layout_width="match_parent"
android:paddingRight="@dimen/default_margin"
android:text="@string/state"/>
<RadioGroup
android:layout_height="wrap_content"
android:layout_width="match_parent">
<SeekBar
android:id="@+id/sbProximity"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:max="100" />
</RadioGroup>
</TableRow>
<TableRow>
<TextView
android:id="@+id/tvWifiTriggerNameLocationNotice"
android:layout_span="2"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:textColor="@color/red"
android:text="@string/locationRequiredToDetermineWifiName"
android:layout_marginVertical="@dimen/default_margin"
android:visibility="gone" />
</TableRow>
</TableLayout>
<TextView
android:id="@+id/tvTriggerProximityHint"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginVertical="@dimen/default_margin"
android:textColor="@color/red"
android:text="@string/deviceDoesntHaveProximitySensor" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/testArea"
android:textAppearance="@style/TextAppearance.AppCompat.Headline" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/testAreaProximityComment" />
<SeekBar
android:id="@+id/sbProximityTest"
android:layout_marginTop="@dimen/default_margin"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<Button
android:id="@+id/bTriggerProximitySave"
android:layout_marginTop="@dimen/default_margin"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/save" />
</androidx.appcompat.widget.LinearLayoutCompat>