relates to FS#299: moves privacy and terms of use urls to build config

This commit is contained in:
steckbrief 2020-04-10 20:45:17 +02:00
parent 815e972b2c
commit ae791a5a4a
3 changed files with 8 additions and 4 deletions

View file

@ -110,6 +110,8 @@ android {
buildConfigField 'String', 'STATICMAP_URL', '"https://piratx.thedevstack.de/staticmap"'
buildConfigField 'String', 'INVITE_HOST', '"jabber.thedevstack.de"'
buildConfigField 'String', 'TERMS_OF_USE_URL', '"https://piratx.thedevstack.de/termsofuse.html"'
buildConfigField 'String', 'PRIVACY_URL', '"https://piratx.thedevstack.de/privacy.html"'
}
dataBinding {

View file

@ -5,6 +5,7 @@ import android.net.Uri;
import android.os.Bundle;
import android.widget.Button;
import de.pixart.messenger.BuildConfig;
import de.pixart.messenger.R;
import de.pixart.messenger.utils.ThemeHelper;
@ -33,13 +34,13 @@ public class AboutActivity extends XmppActivity {
privacyButton = findViewById(R.id.show_privacy_policy);
privacyButton.setOnClickListener(view -> {
final Uri uri = Uri.parse("https://jabber.pix-art.de/privacy/");
final Uri uri = Uri.parse(BuildConfig.PRIVACY_URL);
Intent browserIntent = new Intent(Intent.ACTION_VIEW, uri);
startActivity(browserIntent);
});
termsOfUseButton = findViewById(R.id.show_terms_of_use);
termsOfUseButton.setOnClickListener(view -> {
final Uri uri = Uri.parse("https://jabber.pix-art.de/termsofuse/");
final Uri uri = Uri.parse(BuildConfig.TERMS_OF_USE_URL);
Intent browserIntent = new Intent(Intent.ACTION_VIEW, uri);
startActivity(browserIntent);
});

View file

@ -45,6 +45,7 @@ import java.util.Set;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicInteger;
import de.pixart.messenger.BuildConfig;
import de.pixart.messenger.Config;
import de.pixart.messenger.R;
import de.pixart.messenger.crypto.axolotl.AxolotlService;
@ -625,12 +626,12 @@ public class EditAccountActivity extends OmemoActivity implements OnAccountUpdat
this.binding.accountRegisterNew.setVisibility(View.GONE);
}
this.binding.showPrivacyPolicy.setOnClickListener(view -> {
final Uri uri = Uri.parse("https://jabber.pix-art.de/privacy/");
final Uri uri = Uri.parse(BuildConfig.PRIVACY_URL);
Intent browserIntent = new Intent(Intent.ACTION_VIEW, uri);
startActivity(browserIntent);
});
this.binding.showTermsOfUse.setOnClickListener(view -> {
final Uri uri = Uri.parse("https://jabber.pix-art.de/termsofuse/");
final Uri uri = Uri.parse(BuildConfig.TERMS_OF_USE_URL);
Intent browserIntent = new Intent(Intent.ACTION_VIEW, uri);
startActivity(browserIntent);
});