summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2021-11-28 21:34:53 +0100
committercyBerta <cyberta@riseup.net>2021-11-28 21:34:53 +0100
commit247c0b5eca6ee988ead3e66f1d9ea990385d315e (patch)
tree1941a71f740beb5c20c3cf087fadb13974cd1c6e
parent3228b17f43b232116c192728438954c4c1412ec3 (diff)
use 'recommended location' or the location name instead of 'select location' in the location button
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/base/fragments/EipFragment.java3
-rw-r--r--app/src/main/res/values/strings.xml2
2 files changed, 3 insertions, 2 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/base/fragments/EipFragment.java b/app/src/main/java/se/leap/bitmaskclient/base/fragments/EipFragment.java
index 45c6307a..14673874 100644
--- a/app/src/main/java/se/leap/bitmaskclient/base/fragments/EipFragment.java
+++ b/app/src/main/java/se/leap/bitmaskclient/base/fragments/EipFragment.java
@@ -477,7 +477,8 @@ public class EipFragment extends Fragment implements Observer {
greyscaleBackground();
locationButton.setLocationLoad(UNKNOWN);
locationButton.showBridgeIndicator(false);
- locationButton.setText(getString(R.string.gateway_selection_title));
+ String city = getPreferredCity(getContext());
+ locationButton.setText(city == null ? getString(R.string.gateway_selection_recommended_location) : city);
locationButton.showRecommendedIndicator(false);
mainDescription.setText(R.string.eip_state_insecure);
subDescription.setText(R.string.connection_not_connected);
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index c32e0d3c..9f1e73b1 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -152,7 +152,7 @@
<string name="version_update_error">Update failed.</string>
<string name="version_update_error_permissions">No permissions to install app.</string>
<string name="gateway_selection_title">Select location</string>
- <string name="gateway_selection_recommended_location">Use recommended location</string>
+ <string name="gateway_selection_recommended_location">Recommended location</string>
<string name="gateway_selection_recommended">Recommended</string>
<string name="gateway_selection_manually">Manually select</string>
<string name="gateway_selection_automatic_location">Automatically use best connection.</string>