From bafbfed6c8d8a0ce7fb8ee908bd99a0d39ba8bf7 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Mon, 1 May 2023 08:50:13 -0500 Subject: [PATCH] Fdroid people are worried about leaking jids --- .../ui/StartConversationActivity.java | 20 +++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/ui/StartConversationActivity.java b/src/main/java/eu/siacs/conversations/ui/StartConversationActivity.java index a24e919f9..3f78b1c87 100644 --- a/src/main/java/eu/siacs/conversations/ui/StartConversationActivity.java +++ b/src/main/java/eu/siacs/conversations/ui/StartConversationActivity.java @@ -1032,8 +1032,24 @@ public class StartConversationActivity extends XmppActivity implements XmppConne }); }); } else { - startCommand(selectedAccount, Jid.of("cheogram.com/CHEOGRAM%jabber:iq:register"), "jabber:iq:register"); - finish(); + if (onboardingAccount == null) { + final Account selAccount = selectedAccount; + AlertDialog.Builder builder = new AlertDialog.Builder(this); + builder.setTitle("Setup Phone Service?"); + builder.setMessage("Would you like to set up a phone number provider now?"); + builder.setPositiveButton(R.string.yes, (dialog, which) -> { + startCommand(selAccount, Jid.of("cheogram.com/CHEOGRAM%jabber:iq:register"), "jabber:iq:register"); + finish(); + }); + builder.setNegativeButton(R.string.no, (dialog, which) -> { + }); + final AlertDialog dialog = builder.create(); + dialog.setCanceledOnTouchOutside(false); + dialog.show(); + } else { + startCommand(selectedAccount, Jid.of("cheogram.com/CHEOGRAM%jabber:iq:register"), "jabber:iq:register"); + finish(); + } return; } } -- 2.45.2