| | |
| | | import androidx.databinding.DataBindingUtil; |
| | | |
| | | import com.android.app_base.manager.AppManager; |
| | | import com.android.app_base.manager.UserManager; |
| | | import com.android.app_base.utils.GlideUtil; |
| | | import com.android.app_base.utils.ScreenSizeUtils; |
| | | import com.application.zhangshi_app_android.R; |
| | |
| | | //获取字体 |
| | | Typeface typeface = ResourcesCompat.getFont(context, com.android.app_base.R.font.roboto_regular); |
| | | binding.tvName.setTypeface(typeface); |
| | | |
| | | } |
| | | // 使用databinding无法测量view的带内容的准确宽高,所以这里手动设置一下 |
| | | binding.tvGeneration.setText(bean.getIdentity()+""); |
| | | if (bean.getNickName().equals(UserManager.getInstance().getUserName())){ |
| | | binding.cvContainer.setCardBackgroundColor(Color.parseColor("#FFCEE4FD")); |
| | | binding.ivMyself.setVisibility(View.VISIBLE); |
| | | } |
| | | } |
| | | familyMemberView.measure(View.MeasureSpec.makeMeasureSpec((1 << 30) - 1, View.MeasureSpec.AT_MOST), |
| | | View.MeasureSpec.makeMeasureSpec((1 << 30) - 1, View.MeasureSpec.AT_MOST)); |