indicate broken pep in server info
This commit is contained in:
parent
a95c451f1e
commit
eff173ebc2
|
@ -243,6 +243,10 @@ public class AxolotlService {
|
|||
return sessions.hasAny(contactAddress);
|
||||
}
|
||||
|
||||
public boolean isPepBroken() {
|
||||
return this.pepBroken;
|
||||
}
|
||||
|
||||
public void regenerateKeys() {
|
||||
axolotlStore.regenerate();
|
||||
sessions.clear();
|
||||
|
|
|
@ -29,6 +29,7 @@ import java.util.Set;
|
|||
|
||||
import eu.siacs.conversations.Config;
|
||||
import eu.siacs.conversations.R;
|
||||
import eu.siacs.conversations.crypto.axolotl.AxolotlService;
|
||||
import eu.siacs.conversations.entities.Account;
|
||||
import eu.siacs.conversations.services.XmppConnectionService.OnAccountUpdate;
|
||||
import eu.siacs.conversations.ui.adapter.KnownHostsAdapter;
|
||||
|
@ -538,7 +539,12 @@ public class EditAccountActivity extends XmppActivity implements OnAccountUpdate
|
|||
this.mServerInfoSm.setText(R.string.server_info_unavailable);
|
||||
}
|
||||
if (features.pep()) {
|
||||
this.mServerInfoPep.setText(R.string.server_info_available);
|
||||
AxolotlService axolotlService = this.mAccount.getAxolotlService();
|
||||
if (axolotlService != null && axolotlService.isPepBroken()) {
|
||||
this.mServerInfoPep.setText(R.string.server_info_broken);
|
||||
} else {
|
||||
this.mServerInfoPep.setText(R.string.server_info_available);
|
||||
}
|
||||
} else {
|
||||
this.mServerInfoPep.setText(R.string.server_info_unavailable);
|
||||
}
|
||||
|
|
|
@ -513,4 +513,5 @@
|
|||
<string name="pref_use_white_background">Use white background</string>
|
||||
<string name="pref_use_white_background_summary">Show received messages as black text on a white background</string>
|
||||
<string name="account_status_dns_timeout">Timeout in DNS</string>
|
||||
<string name="server_info_broken">Broken</string>
|
||||
</resources>
|
||||
|
|
Loading…
Reference in New Issue