From a4edfa115d40f9547b2056fd8b6c19f803e2aead Mon Sep 17 00:00:00 2001 From: Dominik Grzelak <dominik.grzelak@tu-dresden.de> Date: Tue, 24 Jul 2018 10:48:28 +0200 Subject: [PATCH] scrollview is now main view for main activity --- mobile/src/main/res/layout/activity_main.xml | 17 ++++++++++------- mobile/src/main/res/values/strings.xml | 4 ++++ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/mobile/src/main/res/layout/activity_main.xml b/mobile/src/main/res/layout/activity_main.xml index 12038cd..c1bdc74 100644 --- a/mobile/src/main/res/layout/activity_main.xml +++ b/mobile/src/main/res/layout/activity_main.xml @@ -1,11 +1,15 @@ <?xml version="1.0" encoding="utf-8"?> -<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" +<ScrollView 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="match_parent" tools:context="de.tudresden.inf.st.sensorsharing.MainActivity"> +<android.support.constraint.ConstraintLayout + android:layout_width="match_parent" + android:layout_height="wrap_content"> + <TextView android:id="@+id/label_own_rotation" android:layout_width="wrap_content" @@ -259,7 +263,7 @@ android:layout_height="wrap_content" android:layout_marginStart="8dp" android:layout_marginTop="8dp" - android:text="Status" + android:text="@string/status" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/separator_wear" /> @@ -267,14 +271,13 @@ android:id="@+id/toggleButton-lightonoff" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginEnd="8dp" android:layout_marginStart="8dp" android:layout_marginTop="8dp" - android:text="Switch On" - android:textOn="Switch Light OFF" - android:textOff="Switch Light ON" - app:layout_constraintEnd_toEndOf="@+id/checkBox_send_rotation_ahrs" + android:text="@string/switch_on" + android:textOff="@string/switch_light_on" + android:textOn="@string/switch_light_off" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/checkBox_send_rotation_ahrs" /> </android.support.constraint.ConstraintLayout> +</ScrollView> diff --git a/mobile/src/main/res/values/strings.xml b/mobile/src/main/res/values/strings.xml index 1224f8a..c7474e2 100644 --- a/mobile/src/main/res/values/strings.xml +++ b/mobile/src/main/res/values/strings.xml @@ -12,4 +12,8 @@ <string name="text_separator_mqtt_settings">MQTT Settings</string> <string name="text_send_updates_brightness">Send Updates Brightness</string> <string name="text_send_updates_rotationahrs">Send Updates Rotation (AHRS)</string> + <string name="status">Status</string> + <string name="switch_on">Switch On</string> + <string name="switch_light_on">Switch Light ON</string> + <string name="switch_light_off">Switch Light OFF</string> </resources> -- GitLab