summaryrefslogtreecommitdiff
path: root/app/src
diff options
context:
space:
mode:
Diffstat (limited to 'app/src')
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/base/fragments/EipFragment.java9
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/base/fragments/SettingsFragment.java47
-rw-r--r--app/src/main/res/values-es/strings.xml5
-rw-r--r--app/src/main/res/values-zh-rCN/strings.xml5
-rw-r--r--app/src/normal/assets/urls/riseup.net.url4
5 files changed, 44 insertions, 26 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 409efcf0..a2fb2683 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
@@ -227,6 +227,12 @@ public class EipFragment extends Fragment implements Observer {
public void onPause() {
super.onPause();
Log.d(TAG, "onPause");
+ if (stateView.getDrawable() instanceof Animatable) {
+ Animatable animatedDrawable = (Animatable) stateView.getDrawable();
+ if (animatedDrawable.isRunning()) {
+ animatedDrawable.stop();
+ }
+ }
}
@Override
@@ -575,6 +581,9 @@ public class EipFragment extends Fragment implements Observer {
@Override
public void onAnimationEnd(Drawable drawable) {
super.onAnimationEnd(drawable);
+ if (!isResumed()) {
+ return;
+ }
if (pendingAnimationState != 0) {
int newAnimationRes = pendingAnimationState;
pendingAnimationState = 0;
diff --git a/app/src/main/java/se/leap/bitmaskclient/base/fragments/SettingsFragment.java b/app/src/main/java/se/leap/bitmaskclient/base/fragments/SettingsFragment.java
index d57d725e..40bc256c 100644
--- a/app/src/main/java/se/leap/bitmaskclient/base/fragments/SettingsFragment.java
+++ b/app/src/main/java/se/leap/bitmaskclient/base/fragments/SettingsFragment.java
@@ -228,14 +228,15 @@ public class SettingsFragment extends Fragment implements SharedPreferences.OnSh
}
private void initGatewayPinningEntry(View rootView) {
+ IconTextEntry gatewayPinning = rootView.findViewById(R.id.gateway_pinning);
if (!BuildConfig.BUILD_TYPE.equals("debug")) {
+ gatewayPinning.setVisibility(GONE);
return;
}
Context context = this.getContext();
if (context == null) {
return;
}
- IconTextEntry gatewayPinning = rootView.findViewById(R.id.gateway_pinning);
String pinnedGateway = PreferenceHelper.getPinnedGateway(rootView.getContext());
gatewayPinning.setSubtitle(pinnedGateway != null ? pinnedGateway : "Connect to a specific Gateway for debugging purposes");
@@ -264,30 +265,30 @@ public class SettingsFragment extends Fragment implements SharedPreferences.OnSh
public void initObfuscationPinningEntry(View rootView) {
IconSwitchEntry obfuscationPinning = rootView.findViewById(R.id.obfuscation_proxy_pinning);
- if (useObfsVpn()) {
- obfuscationPinning.setVisibility(VISIBLE);
- boolean useBridges = getUseBridges(getContext());
- obfuscationPinning.setEnabled(useBridges);
- obfuscationPinning.setSubtitle(useBridges ? "Connect to a specific obfuscation proxy for debugging purposes" : "Enable Bridges to use this option");
- obfuscationPinning.setChecked(useObfuscationPinning(getContext()));
- obfuscationPinning.setOnCheckedChangeListener((buttonView, isChecked) -> {
- if (!buttonView.isPressed()) {
- return;
- }
- if (!isChecked) {
- setUseObfuscationPinning(getContext(), false);
- } else {
- showObfuscationPinningDialog();
- }
- });
- obfuscationPinning.setOnClickListener(v -> {
- if (obfuscationPinning.isChecked()) {
- showObfuscationPinningDialog();
- }
- });
- } else {
+ if (!BuildConfig.BUILD_TYPE.equals("debug") || !useObfsVpn()) {
obfuscationPinning.setVisibility(GONE);
+ return;
}
+ obfuscationPinning.setVisibility(VISIBLE);
+ boolean useBridges = getUseBridges(getContext());
+ obfuscationPinning.setEnabled(useBridges);
+ obfuscationPinning.setSubtitle(useBridges ? "Connect to a specific obfuscation proxy for debugging purposes" : "Enable Bridges to use this option");
+ obfuscationPinning.setChecked(useObfuscationPinning(getContext()));
+ obfuscationPinning.setOnCheckedChangeListener((buttonView, isChecked) -> {
+ if (!buttonView.isPressed()) {
+ return;
+ }
+ if (!isChecked) {
+ setUseObfuscationPinning(getContext(), false);
+ } else {
+ showObfuscationPinningDialog();
+ }
+ });
+ obfuscationPinning.setOnClickListener(v -> {
+ if (obfuscationPinning.isChecked()) {
+ showObfuscationPinningDialog();
+ }
+ });
}
public void showObfuscationPinningDialog() {
diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml
index 3cd933b9..17620753 100644
--- a/app/src/main/res/values-es/strings.xml
+++ b/app/src/main/res/values-es/strings.xml
@@ -67,6 +67,9 @@
<string name="authentication_failed_message">Autentificación fallida</string>
<string name="registration_failed_message">El registro falló.</string>
<string name="eip_status_start_pending">Iniciando conexión</string>
+ <string name="eip_status_connecting">Conectando a VPN</string>
+ <string name="eip_status_unsecured">Conexión Insegura</string>
+ <string name="eip_status_secured">Conexión Segura</string>
<string name="eip_cancel_connect_title">¿Cancelar conexión?</string>
<string name="eip_cancel_connect_text">Se está intentando establecer la conexión. ¿Desea cancelarla?</string>
<string name="eip.warning.browser_inconsistency">¿Desactivar la conexión VPN? Cuando la VPN está desactivada, su información personal se puede filtrar a su proveedor de Internet o red local.</string>
@@ -202,4 +205,6 @@
<string name="disabled_while_udp_on">Deshabilitado mientras UDP está activado.</string>
<string name="advanced_settings">Configuración avanzada</string>
<string name="cancel_connection">Desconectar</string>
+ <string name="unknown_location">Ubicación desconocida</string>
+ <string name="splash_footer">Desarrollado por LEAP</string>
</resources>
diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/app/src/main/res/values-zh-rCN/strings.xml
index 564f15f3..9279450d 100644
--- a/app/src/main/res/values-zh-rCN/strings.xml
+++ b/app/src/main/res/values-zh-rCN/strings.xml
@@ -67,6 +67,9 @@
<string name="authentication_failed_message">认证失败</string>
<string name="registration_failed_message">注册失败</string>
<string name="eip_status_start_pending">正在初始化连接</string>
+ <string name="eip_status_connecting">正在连接 VPN</string>
+ <string name="eip_status_unsecured">不安全连接</string>
+ <string name="eip_status_secured">安全连接</string>
<string name="eip_cancel_connect_title">取消连接?</string>
<string name="eip_cancel_connect_text">尝试连接中。您希望取消吗?</string>
<string name="eip.warning.browser_inconsistency">是否关闭 VPN 连接?关闭 VPN 可能会造成向您的互联网提供商或本地网络泄露个人信息的后果。</string>
@@ -200,4 +203,6 @@
<string name="disabled_while_udp_on">UDP 开启时禁用。</string>
<string name="advanced_settings">高级设置</string>
<string name="cancel_connection">中断连接</string>
+ <string name="unknown_location">未知位置</string>
+ <string name="splash_footer">由 LEAP 开发</string>
</resources>
diff --git a/app/src/normal/assets/urls/riseup.net.url b/app/src/normal/assets/urls/riseup.net.url
index ad24ee99..474580da 100644
--- a/app/src/normal/assets/urls/riseup.net.url
+++ b/app/src/normal/assets/urls/riseup.net.url
@@ -1,7 +1,5 @@
{
"main_url" : "https://black.riseup.net",
- "provider_ip" : "198.252.153.70",
- "provider_api_ip" : "198.252.153.107",
- "geoip_url" : "https://api.black.riseup.net:9001/json",
+ "geoip_url" : "https://menshen.riseup.net/json",
"motd_url": "https://static.riseup.net/vpn/motd.json"
}