summaryrefslogtreecommitdiffhomepage
path: root/android/src
diff options
context:
space:
mode:
Diffstat (limited to 'android/src')
-rw-r--r--android/src/main/res/layout/account.xml13
-rw-r--r--android/src/main/res/layout/advanced.xml8
-rw-r--r--android/src/main/res/layout/connect.xml3
-rw-r--r--android/src/main/res/layout/login.xml2
-rw-r--r--android/src/main/res/layout/out_of_time.xml8
-rw-r--r--android/src/main/res/layout/preferences.xml6
-rw-r--r--android/src/main/res/layout/problem_report.xml2
-rw-r--r--android/src/main/res/layout/redeem_voucher.xml2
-rw-r--r--android/src/main/res/layout/select_location_header.xml2
-rw-r--r--android/src/main/res/layout/settings.xml9
-rw-r--r--android/src/main/res/layout/split_tunnelling_header.xml6
-rw-r--r--android/src/main/res/layout/welcome.xml7
-rw-r--r--android/src/main/res/layout/wireguard_key.xml14
-rw-r--r--android/src/main/res/values/dimensions.xml4
14 files changed, 46 insertions, 40 deletions
diff --git a/android/src/main/res/layout/account.xml b/android/src/main/res/layout/account.xml
index 3dc83b7745..bf374b2ebb 100644
--- a/android/src/main/res/layout/account.xml
+++ b/android/src/main/res/layout/account.xml
@@ -34,12 +34,11 @@
<LinearLayout android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="4dp"
- android:layout_marginBottom="24dp"
android:orientation="vertical">
<TextView android:id="@+id/expanded_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginBottom="12dp"
+ android:layout_marginBottom="@dimen/half_vertical_space"
android:layout_marginHorizontal="@dimen/side_margin"
android:text="@string/settings_account"
style="@style/SettingsExpandedHeader" />
@@ -47,7 +46,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="12dp"
+ android:paddingVertical="@dimen/half_vertical_space"
mullvad:clipboardLabel="@string/mullvad_account_number"
mullvad:copiedToast="@string/copied_mullvad_account_number"
mullvad:description="@string/account_number"
@@ -56,13 +55,13 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="12dp"
+ android:paddingVertical="@dimen/half_vertical_space"
mullvad:description="@string/paid_until"
mullvad:whenMissing="hide" />
<net.mullvad.mullvadvpn.ui.widget.UrlButton android:id="@+id/buy_credit"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="12dp"
+ android:layout_marginTop="@dimen/half_vertical_space"
android:layout_marginHorizontal="@dimen/side_margin"
mullvad:showSpinner="true"
mullvad:url="@string/account_url"
@@ -72,7 +71,7 @@
<net.mullvad.mullvadvpn.ui.widget.Button android:id="@+id/redeem_voucher"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginVertical="@dimen/button_separation"
android:layout_marginHorizontal="@dimen/side_margin"
mullvad:text="@string/redeem_voucher"
mullvad:buttonColor="green" />
@@ -80,7 +79,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginHorizontal="@dimen/side_margin"
- android:layout_marginVertical="24dp"
+ android:layout_marginBottom="@dimen/screen_vertical_margin"
mullvad:text="@string/log_out"
mullvad:buttonColor="red" />
</LinearLayout>
diff --git a/android/src/main/res/layout/advanced.xml b/android/src/main/res/layout/advanced.xml
index 77b5574beb..f9cb370089 100644
--- a/android/src/main/res/layout/advanced.xml
+++ b/android/src/main/res/layout/advanced.xml
@@ -33,7 +33,7 @@
<LinearLayout android:layout_width="match_parent"
android:layout_height="match_parent"
- android:paddingBottom="24dp"
+ android:paddingBottom="@dimen/screen_vertical_margin"
android:orientation="vertical">
<TextView android:id="@+id/expanded_title"
android:layout_width="wrap_content"
@@ -45,17 +45,17 @@
<net.mullvad.mullvadvpn.ui.widget.MtuCell android:id="@+id/wireguard_mtu"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/wireguard_mtu" />
<net.mullvad.mullvadvpn.ui.widget.NavigateCell android:id="@+id/wireguard_keys"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/wireguard_key" />
<net.mullvad.mullvadvpn.ui.widget.NavigateCell android:id="@+id/split_tunnelling"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/split_tunnelling" />
</LinearLayout>
</net.mullvad.mullvadvpn.ui.widget.ListenableScrollView>
diff --git a/android/src/main/res/layout/connect.xml b/android/src/main/res/layout/connect.xml
index 24a9b8d90f..a2602dc028 100644
--- a/android/src/main/res/layout/connect.xml
+++ b/android/src/main/res/layout/connect.xml
@@ -116,7 +116,8 @@
android:layout_weight="0"
android:orientation="vertical"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="24dp">
+ android:paddingTop="@dimen/vertical_space"
+ android:paddingBottom="@dimen/screen_vertical_margin">
<Button android:id="@+id/switch_location"
android:layout_marginTop="20dp"
android:layout_marginBottom="16dp"
diff --git a/android/src/main/res/layout/login.xml b/android/src/main/res/layout/login.xml
index 5413e927d4..a067831296 100644
--- a/android/src/main/res/layout/login.xml
+++ b/android/src/main/res/layout/login.xml
@@ -107,7 +107,7 @@
android:layout_weight="0"
android:orientation="vertical"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingBottom="24dp"
+ android:paddingBottom="@dimen/screen_vertical_margin"
android:paddingTop="16dp"
android:background="@color/darkBlue">
<TextView android:layout_width="match_parent"
diff --git a/android/src/main/res/layout/out_of_time.xml b/android/src/main/res/layout/out_of_time.xml
index 568c75d408..544413d22c 100644
--- a/android/src/main/res/layout/out_of_time.xml
+++ b/android/src/main/res/layout/out_of_time.xml
@@ -16,7 +16,7 @@
<ImageView android:layout_width="60dp"
android:layout_height="60dp"
android:layout_gravity="center"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/screen_vertical_margin"
android:layout_marginBottom="18dp"
android:src="@drawable/icon_fail" />
<TextView android:layout_width="wrap_content"
@@ -42,18 +42,19 @@
android:layout_weight="0"
android:orientation="vertical"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="24dp"
+ android:paddingBottom="@dimen/screen_vertical_margin"
android:background="@color/darkBlue">
<net.mullvad.mullvadvpn.ui.widget.Button android:id="@+id/disconnect"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginBottom="24dp"
+ android:layout_marginTop="@dimen/button_separation"
android:visibility="gone"
mullvad:buttonColor="red"
mullvad:text="@string/disconnect" />
<net.mullvad.mullvadvpn.ui.widget.UrlButton android:id="@+id/buy_credit"
android:layout_width="match_parent"
android:layout_height="wrap_content"
+ android:layout_marginVertical="@dimen/button_separation"
mullvad:buttonColor="green"
mullvad:text="@string/buy_more_credit"
mullvad:url="@string/account_url"
@@ -61,7 +62,6 @@
<net.mullvad.mullvadvpn.ui.widget.Button android:id="@+id/redeem_voucher"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
mullvad:buttonColor="green"
mullvad:text="@string/redeem_voucher" />
</LinearLayout>
diff --git a/android/src/main/res/layout/preferences.xml b/android/src/main/res/layout/preferences.xml
index b0891c4e49..05b9702a5e 100644
--- a/android/src/main/res/layout/preferences.xml
+++ b/android/src/main/res/layout/preferences.xml
@@ -33,7 +33,7 @@
<LinearLayout android:layout_width="match_parent"
android:layout_height="match_parent"
- android:paddingBottom="24dp"
+ android:paddingBottom="@dimen/screen_vertical_margin"
android:orientation="vertical">
<TextView android:id="@+id/expanded_title"
android:layout_width="wrap_content"
@@ -45,13 +45,13 @@
<net.mullvad.mullvadvpn.ui.widget.ToggleCell android:id="@+id/auto_connect"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/auto_connect"
mullvad:footer="@string/auto_connect_footer" />
<net.mullvad.mullvadvpn.ui.widget.ToggleCell android:id="@+id/allow_lan"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/local_network_sharing"
mullvad:footer="@string/allow_lan_footer" />
</LinearLayout>
diff --git a/android/src/main/res/layout/problem_report.xml b/android/src/main/res/layout/problem_report.xml
index c1a2d48517..8c8dba11dd 100644
--- a/android/src/main/res/layout/problem_report.xml
+++ b/android/src/main/res/layout/problem_report.xml
@@ -52,7 +52,7 @@
<TextView android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="0"
- android:layout_marginBottom="24dp"
+ android:layout_marginBottom="@dimen/vertical_space"
android:layout_marginHorizontal="@dimen/side_margin"
android:textColor="@color/white80"
android:textSize="@dimen/text_small"
diff --git a/android/src/main/res/layout/redeem_voucher.xml b/android/src/main/res/layout/redeem_voucher.xml
index 1594f5e3fe..aa0b360aa8 100644
--- a/android/src/main/res/layout/redeem_voucher.xml
+++ b/android/src/main/res/layout/redeem_voucher.xml
@@ -46,7 +46,7 @@
<net.mullvad.mullvadvpn.ui.widget.Button android:id="@+id/redeem"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginVertical="16dp"
+ android:layout_marginVertical="@dimen/button_separation"
mullvad:showSpinner="true"
mullvad:buttonColor="green"
mullvad:text="@string/redeem" />
diff --git a/android/src/main/res/layout/select_location_header.xml b/android/src/main/res/layout/select_location_header.xml
index 46fd46ff38..394196ef87 100644
--- a/android/src/main/res/layout/select_location_header.xml
+++ b/android/src/main/res/layout/select_location_header.xml
@@ -15,7 +15,7 @@
android:layout_height="wrap_content"
android:layout_weight="0"
android:layout_marginHorizontal="@dimen/side_margin"
- android:layout_marginBottom="24dp"
+ android:layout_marginBottom="@dimen/vertical_space"
android:textColor="@color/white60"
android:textSize="@dimen/text_small"
android:text="@string/select_location_description" />
diff --git a/android/src/main/res/layout/settings.xml b/android/src/main/res/layout/settings.xml
index 19b463bcf1..72fd6195db 100644
--- a/android/src/main/res/layout/settings.xml
+++ b/android/src/main/res/layout/settings.xml
@@ -46,7 +46,7 @@
<net.mullvad.mullvadvpn.ui.widget.AccountCell android:id="@+id/account"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/settings_account" />
<net.mullvad.mullvadvpn.ui.widget.NavigateCell android:id="@+id/preferences"
android:layout_width="match_parent"
@@ -61,17 +61,18 @@
<net.mullvad.mullvadvpn.ui.widget.AppVersionCell android:id="@+id/app_version"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="1dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/app_version"
mullvad:footer="@string/update_available_footer" />
<net.mullvad.mullvadvpn.ui.widget.NavigateCell android:id="@+id/report_a_problem"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/report_a_problem" />
<Button android:id="@+id/quit_button"
android:layout_marginHorizontal="@dimen/side_margin"
- android:layout_marginVertical="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
+ android:layout_marginBottom="@dimen/screen_vertical_margin"
android:text="@string/quit"
style="@style/RedButton" />
</LinearLayout>
diff --git a/android/src/main/res/layout/split_tunnelling_header.xml b/android/src/main/res/layout/split_tunnelling_header.xml
index 7e58aa8a8c..359bf1f7e8 100644
--- a/android/src/main/res/layout/split_tunnelling_header.xml
+++ b/android/src/main/res/layout/split_tunnelling_header.xml
@@ -23,12 +23,12 @@
<net.mullvad.mullvadvpn.ui.widget.ToggleCell android:id="@+id/enabled"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
mullvad:text="@string/enabled" />
<LinearLayout android:id="@+id/exclude_applications"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
android:paddingHorizontal="16dp"
android:background="@drawable/cell_button_background"
android:visibility="gone"
@@ -47,7 +47,7 @@
android:layout_width="60dp"
android:layout_height="60dp"
android:layout_gravity="center"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/vertical_space"
android:indeterminate="true"
android:indeterminateOnly="true"
android:indeterminateDuration="600"
diff --git a/android/src/main/res/layout/welcome.xml b/android/src/main/res/layout/welcome.xml
index 10b7eca4a7..359ecb88c3 100644
--- a/android/src/main/res/layout/welcome.xml
+++ b/android/src/main/res/layout/welcome.xml
@@ -16,7 +16,7 @@
<TextView android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginHorizontal="@dimen/side_margin"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/screen_vertical_margin"
android:textColor="@color/white"
android:textSize="@dimen/text_huge"
android:textStyle="bold"
@@ -45,6 +45,7 @@
android:layout_height="wrap_content"
android:layout_marginHorizontal="@dimen/side_margin"
android:layout_marginTop="11dp"
+ android:layout_marginBottom="@dimen/vertical_space"
android:textColor="@color/white"
android:textSize="@dimen/text_small" />
<Space android:layout_width="match_parent"
@@ -55,12 +56,12 @@
android:layout_marginTop="16dp"
android:orientation="vertical"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="24dp"
+ android:paddingBottom="@dimen/screen_vertical_margin"
android:background="@color/darkBlue">
<net.mullvad.mullvadvpn.ui.widget.UrlButton android:id="@+id/buy_credit"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginBottom="24dp"
+ android:layout_marginVertical="@dimen/button_separation"
mullvad:buttonColor="green"
mullvad:text="@string/buy_credit"
mullvad:url="@string/account_url"
diff --git a/android/src/main/res/layout/wireguard_key.xml b/android/src/main/res/layout/wireguard_key.xml
index 714a3b4025..389b0a1695 100644
--- a/android/src/main/res/layout/wireguard_key.xml
+++ b/android/src/main/res/layout/wireguard_key.xml
@@ -40,7 +40,7 @@
android:layout_weight="0"
android:layout_marginLeft="@dimen/side_margin"
android:layout_marginTop="4dp"
- android:layout_marginBottom="12dp"
+ android:layout_marginBottom="@dimen/half_vertical_space"
android:text="@string/wireguard_key"
style="@style/SettingsExpandedHeader" />
<net.mullvad.mullvadvpn.ui.widget.CopyableInformationView android:id="@+id/public_key"
@@ -48,7 +48,7 @@
android:layout_height="wrap_content"
android:layout_weight="0"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="12dp"
+ android:paddingVertical="@dimen/half_vertical_space"
mullvad:clipboardLabel="@string/wireguard_public_key"
mullvad:copiedToast="@string/copied_wireguard_public_key"
mullvad:description="@string/public_key"
@@ -59,13 +59,13 @@
android:layout_height="wrap_content"
android:layout_weight="0"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="12dp"
+ android:paddingVertical="@dimen/half_vertical_space"
mullvad:description="@string/wireguard_key_generated"
mullvad:whenMissing="showSpinner" />
<FrameLayout android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingHorizontal="@dimen/side_margin"
- android:paddingVertical="12dp">
+ android:paddingVertical="@dimen/half_vertical_space">
<TextView android:id="@+id/wireguard_key_status"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -98,7 +98,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="0"
- android:layout_marginTop="24dp"
+ android:layout_marginTop="@dimen/button_separation"
android:layout_marginHorizontal="@dimen/side_margin"
mullvad:buttonColor="blue"
mullvad:text="@string/wireguard_verify_key"
@@ -107,8 +107,8 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="0"
- android:layout_marginTop="24dp"
- android:layout_marginBottom="24dp"
+ android:layout_marginTop="@dimen/button_separation"
+ android:layout_marginBottom="@dimen/screen_vertical_margin"
android:layout_marginHorizontal="@dimen/side_margin"
mullvad:text="@string/wireguard_manage_keys"
mullvad:buttonColor="blue"
diff --git a/android/src/main/res/values/dimensions.xml b/android/src/main/res/values/dimensions.xml
index 57957c94e6..4dcb214407 100644
--- a/android/src/main/res/values/dimensions.xml
+++ b/android/src/main/res/values/dimensions.xml
@@ -30,4 +30,8 @@
<dimen name="text_big">24sp</dimen>
<dimen name="text_huge">30sp</dimen>
<dimen name="side_margin">22dp</dimen>
+ <dimen name="vertical_space">20dp</dimen>
+ <dimen name="half_vertical_space">10dp</dimen>
+ <dimen name="button_separation">18dp</dimen>
+ <dimen name="screen_vertical_margin">22dp</dimen>
</resources>