summaryrefslogtreecommitdiff
path: root/app/src/main/res/layout
diff options
context:
space:
mode:
Diffstat (limited to 'app/src/main/res/layout')
-rw-r--r--app/src/main/res/layout/fragment_dashboard.xml92
1 files changed, 41 insertions, 51 deletions
diff --git a/app/src/main/res/layout/fragment_dashboard.xml b/app/src/main/res/layout/fragment_dashboard.xml
index 93c1d36..97751a1 100644
--- a/app/src/main/res/layout/fragment_dashboard.xml
+++ b/app/src/main/res/layout/fragment_dashboard.xml
@@ -21,49 +21,57 @@
android:layout_width="match_parent"
android:orientation="vertical"
>
-
- <TextView
- android:id="@+id/state_label"
+ <LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
- android:layout_marginBottom="4dp"
- android:text="@string/dashboard_state_subtitle_off"
- android:textColor="@color/orange_off"
- android:gravity="center"
- />
- <TextView
- android:id="@+id/state_subtitle"
+ android:orientation="horizontal"
+ android:gravity="center_vertical">
+ <ImageView
+ android:id="@+id/state_icon"
+ android:layout_height="25dp"
+ android:layout_width="24dp"
+ android:layout_margin="16dp"
+ android:src="@drawable/ic_shield_off"
+ android:scaleType="fitCenter"
+ />
+ <TextView
+ android:id="@+id/state_label"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:text="@string/dashboard_state_title_off"
+ android:textSize="14sp"
+ android:textColor="@color/grey_text"
+ />
+ <Switch
+ android:id="@+id/toggle_privacy_central"
+ android:layout_height="wrap_content"
+ android:layout_width="wrap_content"
+ android:layout_margin="16dp"
+ />
+ </LinearLayout>
+ <View
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:text="@string/dashboard_state_title_on"
- android:gravity="center"
- android:textSize="12sp"
- android:textColor="@color/grey_text_2"
+ android:layout_height="1dp"
+ android:background="@color/grey_divider"
/>
- <ImageView
- android:id="@+id/toggle_privacy_central"
- android:layout_height="120dp"
- android:layout_margin="32dp"
- android:layout_width="120dp"
- android:src="@drawable/ic_quick_privacy_off"
- android:scaleType="fitCenter"
- android:background="?attr/selectableItemBackgroundBorderless"
- />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="16dp"
- android:layout_marginBottom="32dp">
+
+ android:layout_marginTop="8dp"
+ android:layout_marginBottom="16dp">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
- android:gravity="center">
+ android:paddingStart="8dp"
+ >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -87,7 +95,8 @@
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
- android:gravity="center">
+ android:paddingStart="8dp"
+ >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -111,7 +120,8 @@
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
- android:gravity="center">
+ android:paddingStart="8dp"
+ >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -147,6 +157,7 @@ android:text="@string/dashboard_state_ipaddress_off"
android:paddingBottom="16dp"
>
<TextView
+ android:id="@+id/graph_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/dashboard_graph_label"
@@ -155,32 +166,11 @@ android:text="@string/dashboard_state_ipaddress_off"
app:layout_constraintTop_toTopOf="parent"
/>
- <TextView
- android:id="@+id/graph_period"
- android:layout_height="wrap_content"
- android:layout_width="wrap_content"
- android:text="@string/dashboard_graph_period"
- android:textSize="14sp"
- android:textColor="@color/grey_text_2"
- app:layout_constraintRight_toRightOf="parent"
- app:layout_constraintTop_toTopOf="parent"
- android:layout_marginRight="16dp"
- />
-
-<!-- <TextView-->
-<!-- android:id="@+id/graph_total"-->
-<!-- android:layout_width="wrap_content"-->
-<!-- android:layout_height="wrap_content"-->
-<!-- android:text="200 hits"-->
-<!-- app:layout_constraintRight_toRightOf="parent"-->
-<!-- app:layout_constraintTop_toBottomOf="@+id/graph_period"-->
-<!-- />-->
-
<com.github.mikephil.charting.charts.BarChart
android:id="@+id/graph"
android:layout_height="144dp"
android:layout_width="match_parent"
- app:layout_constraintTop_toBottomOf="@+id/graph_period"
+ app:layout_constraintTop_toBottomOf="@+id/graph_title"
android:layout_marginTop="16dp"
/>