summaryrefslogtreecommitdiff
path: root/app/java/res
diff options
context:
space:
mode:
authorDaniel Weipert <code@drogueronin.de>2023-05-14 23:00:00 +0200
committerDaniel Weipert <code@drogueronin.de>2023-05-14 23:00:00 +0200
commit08b40e81c62420e977e82189482fc07c0d6ace31 (patch)
tree59848b81e4c24945a35846f42215c336aaeb13ae /app/java/res
parentde738691db03ff61bf292b75bfa716b75fe34af1 (diff)
menu / settings
Diffstat (limited to 'app/java/res')
-rw-r--r--app/java/res/layout/main.xml1
-rw-r--r--app/java/res/layout/settings.xml26
-rw-r--r--app/java/res/xml/settings.xml30
3 files changed, 30 insertions, 27 deletions
diff --git a/app/java/res/layout/main.xml b/app/java/res/layout/main.xml
index 1658965..cc1780c 100644
--- a/app/java/res/layout/main.xml
+++ b/app/java/res/layout/main.xml
@@ -19,7 +19,6 @@
/>
<Button
- style="@style/button_start__start"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/button_start"
diff --git a/app/java/res/layout/settings.xml b/app/java/res/layout/settings.xml
deleted file mode 100644
index 5ba8c78..0000000
--- a/app/java/res/layout/settings.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<FrameLayout
- xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:tools="http://schemas.android.com/tools"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:paddingLeft="@dimen/activity_horizontal_margin"
- android:paddingRight="@dimen/activity_horizontal_margin"
- android:paddingTop="@dimen/activity_vertical_margin"
- android:paddingBottom="@dimen/activity_vertical_margin"
- android:orientation="vertical"
- tools:context=".SettingsActivity"
->
-
- <TextureView
- android:layout_width="fill_parent"
- android:layout_height="wrap_content"
- android:id="@+id/surface_view"
- />
-
- <!-- USE_WIFI_LISTENER -->
- <!-- SELECT_FROM_KNOWN_SSIDS -->
-
- <!-- USE_AUTOMATIC_DNS/PIHOLE_SERVER_DISCOVERY -->
- <!-- SET_MANUAL_DNS/PIHOLE_SERVER_IP -->
-</FrameLayout>
diff --git a/app/java/res/xml/settings.xml b/app/java/res/xml/settings.xml
new file mode 100644
index 0000000..ea44ce0
--- /dev/null
+++ b/app/java/res/xml/settings.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<PreferenceScreen
+ xmlns:android="http://schemas.android.com/apk/res/android"
+>
+ <SwitchPreference
+ android:key="use_automatic_dns_server_discovery"
+ android:defaultValue="true"
+ android:title="Use automatic DNS Server / Pihole discovery"
+ android:summary="Whether to use the automatic discovery mechanism to set the DNS server"
+ />
+
+ <SwitchPreference
+ android:key="use_wifi_listener"
+ android:defaultValue="false"
+ android:title="Use WiFi listener"
+ android:summary="Automatically de/activates the proxy on WiFi dis/connect"
+ />
+
+ <!-- USE_WIFI_LISTENER -->
+ <!-- SELECT_FROM_KNOWN_SSIDS -->
+ <!-- <MultiSelectListPreference -->
+ <!-- android:id="@+id/known_ssids" -->
+ <!-- android:key="known_ssids" -->
+ <!-- android:entries="" -->
+ <!-- android:entryValues="" -->
+ <!-- /> -->
+
+ <!-- USE_AUTOMATIC_DNS/PIHOLE_SERVER_DISCOVERY -->
+ <!-- SET_MANUAL_DNS/PIHOLE_SERVER_IP -->
+</PreferenceScreen>