Fixed identity type icon

This commit is contained in:
M66B 2024-06-02 09:59:00 +02:00
parent d7c8f6ac24
commit 93bb5ae430
1 changed files with 4 additions and 3 deletions

View File

@ -19,6 +19,7 @@ package eu.faircode.email;
Copyright 2018-2024 by Marcel Bokhorst (M66B)
*/
import static eu.faircode.email.ServiceAuthenticator.AUTH_TYPE_GMAIL;
import static eu.faircode.email.ServiceAuthenticator.AUTH_TYPE_OAUTH;
import static eu.faircode.email.ServiceAuthenticator.AUTH_TYPE_PASSWORD;
@ -141,9 +142,9 @@ public class AdapterIdentity extends RecyclerView.Adapter<AdapterIdentity.ViewHo
ivSync.setContentDescription(context.getString(identity.synchronize ? R.string.title_legend_synchronize_on : R.string.title_legend_synchronize_off));
ivOAuth.setVisibility(identity.auth_type == AUTH_TYPE_PASSWORD ? View.GONE : View.VISIBLE);
ivOAuth.setImageResource(identity.auth_type == AUTH_TYPE_OAUTH
? R.drawable.twotone_security_24
: R.drawable.twotone_hub_24);
ivOAuth.setImageResource(
identity.auth_type == AUTH_TYPE_GMAIL || identity.auth_type == AUTH_TYPE_OAUTH
? R.drawable.twotone_security_24 : R.drawable.twotone_hub_24);
ivPrimary.setVisibility(identity.primary ? View.VISIBLE : View.GONE);
ivGroup.setVisibility(identity.self ? View.GONE : View.VISIBLE);
tvName.setText(identity.getDisplayName());