hide phone number

This commit is contained in:
Riko Sakurauchi 2019-06-20 20:29:59 +08:00
parent 5bc372093d
commit 2299a7a250
No known key found for this signature in database
GPG Key ID: 25AC0345B92902AF
1 changed files with 5 additions and 1 deletions

View File

@ -40,6 +40,8 @@ import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.ActionBar.Theme;
import org.telegram.ui.Components.SnowflakesEffect;
import tw.nekomimi.nekogram.NekoConfig;
public class DrawerProfileCell extends FrameLayout {
private BackupImageView avatarImageView;
@ -198,7 +200,9 @@ public class DrawerProfileCell extends FrameLayout {
accountsShowed = accounts;
arrowView.setImageResource(accountsShowed ? R.drawable.collapse_up : R.drawable.collapse_down);
nameTextView.setText(UserObject.getUserName(user));
phoneTextView.setText(PhoneFormat.getInstance().format("+" + user.phone));
if (!NekoConfig.hidePhone) {
phoneTextView.setText(PhoneFormat.getInstance().format("+" + user.phone));
}
AvatarDrawable avatarDrawable = new AvatarDrawable(user);
avatarDrawable.setColor(Theme.getColor(Theme.key_avatar_backgroundInProfileBlue));
avatarImageView.setImage(ImageLocation.getForUser(user, false), "50_50", avatarDrawable, user);