接口 改造
This commit is contained in:
@@ -239,15 +239,15 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
|
||||
mVotes.setText(bean.getTotalCoinFormat() + " ");
|
||||
mSex.setImageResource(CommonIconUtil.getSexIcon(bean.getSex()));
|
||||
LevelBean levelBean = null;
|
||||
if (mType == TYPE_PROFIT) {
|
||||
levelBean = CommonAppConfig.getInstance().getAnchorLevel(bean.getLevelAnchor());
|
||||
} else {
|
||||
levelBean = CommonAppConfig.getInstance().getLevel(bean.getLevel());
|
||||
}
|
||||
if (levelBean != null) {
|
||||
ImgLoader.display(mContext, levelBean.getThumb(), mLevel);
|
||||
}
|
||||
// LevelBean levelBean = null;
|
||||
// if (mType == TYPE_PROFIT) {
|
||||
// levelBean = CommonAppConfig.getInstance().getAnchorLevel(bean.getLevelAnchor());
|
||||
// } else {
|
||||
// levelBean = CommonAppConfig.getInstance().getLevel(bean.getLevel());
|
||||
// }
|
||||
// if (levelBean != null) {
|
||||
// ImgLoader.display(mContext, levelBean.getThumb(), mLevel);
|
||||
// }
|
||||
}
|
||||
liveing.setVisibility(View.INVISIBLE);
|
||||
if (bean.getIslive() == 1) {
|
||||
|
||||
@@ -16,15 +16,17 @@ import com.yunbao.common.Constants;
|
||||
import com.yunbao.common.adapter.RefreshAdapter;
|
||||
import com.yunbao.common.bean.LevelBean;
|
||||
import com.yunbao.common.bean.LiveBean;
|
||||
import com.yunbao.common.bean.NewLevelModel;
|
||||
import com.yunbao.common.custom.MyRadioButton;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.CommonHttpUtil;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
import com.yunbao.common.http.LiveHttpUtil;
|
||||
import com.yunbao.common.manager.NewLevelManager;
|
||||
import com.yunbao.common.utils.CommonIconUtil;
|
||||
import com.yunbao.common.utils.LiveRoomCheckLivePresenter;
|
||||
import com.yunbao.common.utils.RouteUtil;
|
||||
import com.yunbao.live.bean.SearchUserBean;
|
||||
import com.yunbao.common.http.LiveHttpUtil;
|
||||
import com.yunbao.common.utils.LiveRoomCheckLivePresenter;
|
||||
import com.yunbao.main.R;
|
||||
|
||||
import java.util.List;
|
||||
@@ -47,8 +49,8 @@ public class SearchAdapter extends RefreshAdapter<SearchUserBean> {
|
||||
public SearchAdapter(Context context, int from) {
|
||||
super(context);
|
||||
mFrom = from;
|
||||
mFollow =mContext.getString(R.string.follow);
|
||||
mFollowing =mContext.getString(R.string.following);
|
||||
mFollow = mContext.getString(R.string.follow);
|
||||
mFollowing = mContext.getString(R.string.following);
|
||||
mFollowClickListener = new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
@@ -117,7 +119,7 @@ public class SearchAdapter extends RefreshAdapter<SearchUserBean> {
|
||||
class Vh extends RecyclerView.ViewHolder {
|
||||
|
||||
ImageView mAvatar;
|
||||
TextView mName;
|
||||
TextView mName, leave;
|
||||
TextView mSign;
|
||||
ImageView mSex;
|
||||
ImageView mLevelAnchor;
|
||||
@@ -130,6 +132,7 @@ public class SearchAdapter extends RefreshAdapter<SearchUserBean> {
|
||||
mAvatar = (ImageView) itemView.findViewById(R.id.avatar);
|
||||
mName = (TextView) itemView.findViewById(R.id.name);
|
||||
mSign = (TextView) itemView.findViewById(R.id.sign);
|
||||
leave = (TextView) itemView.findViewById(R.id.leave);
|
||||
mSex = (ImageView) itemView.findViewById(R.id.sex);
|
||||
mLevelAnchor = (ImageView) itemView.findViewById(R.id.level_anchor);
|
||||
mLevel = (ImageView) itemView.findViewById(R.id.level);
|
||||
@@ -158,31 +161,24 @@ public class SearchAdapter extends RefreshAdapter<SearchUserBean> {
|
||||
gotoLive(bean.getId());
|
||||
}
|
||||
});
|
||||
LevelBean anchorLevelBean = CommonAppConfig.getInstance().getAnchorLevel(bean.getLevelAnchor());
|
||||
if (anchorLevelBean != null) {
|
||||
ImgLoader.display(mContext, CommonAppConfig.getInstance().HOST + anchorLevelBean.getThumb(), mLevelAnchor);
|
||||
List<NewLevelModel> models = new NewLevelManager(itemView.getContext()).getNewAnchorLevelModels();
|
||||
int anchorLevel = 0;
|
||||
anchorLevel = bean.getLevelAnchor();
|
||||
String imgUrl = "";
|
||||
for (NewLevelModel newLevelModel : models) {
|
||||
if (newLevelModel.getLeveMin() <= anchorLevel && anchorLevel <= newLevelModel.getLeveMax()) {
|
||||
imgUrl = newLevelModel.getThumb();
|
||||
}
|
||||
}
|
||||
leave.setText(bean.getLevelAnchor() + "");
|
||||
ImgLoader.display(itemView.getContext(), imgUrl, mLevelAnchor);
|
||||
|
||||
LevelBean levelBean = CommonAppConfig.getInstance().getLevel(bean.getLevel());
|
||||
if (levelBean != null) {
|
||||
ImgLoader.display(mContext, levelBean.getThumb(), mLevel);
|
||||
}
|
||||
}
|
||||
// if (mUid.equals(bean.getId())) {
|
||||
// if (mBtnFollow.getVisibility() == View.VISIBLE) {
|
||||
// mBtnFollow.setVisibility(View.INVISIBLE);
|
||||
// }
|
||||
// } else {
|
||||
// if (mBtnFollow.getVisibility() != View.VISIBLE) {
|
||||
// mBtnFollow.setVisibility(View.VISIBLE);
|
||||
// }
|
||||
// if (bean.getAttention() == 1) {
|
||||
// mBtnFollow.doChecked(true);
|
||||
// mBtnFollow.setText(mFollowing);
|
||||
// } else {
|
||||
// mBtnFollow.doChecked(false);
|
||||
// mBtnFollow.setText(mFollow);
|
||||
// }
|
||||
// }
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -200,7 +196,7 @@ public class SearchAdapter extends RefreshAdapter<SearchUserBean> {
|
||||
new LiveRoomCheckLivePresenter(mContext, liveBean.getUid(), liveBean.getStream(), new LiveRoomCheckLivePresenter.NewActionListener() {
|
||||
@Override
|
||||
public void onLiveRoomChanged(String liveUid, String stream, int liveType, String liveTypeVal, String liveSdk) {
|
||||
RouteUtil.forwardLiveAudienceActivity(liveBean, liveType, Integer.parseInt(liveSdk), Integer.parseInt(liveTypeVal));
|
||||
RouteUtil.forwardLiveAudienceActivity(liveBean, liveType, Integer.parseInt(liveSdk), Integer.parseInt(liveTypeVal));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -2,15 +2,10 @@ package com.yunbao.main.dialog;
|
||||
|
||||
import static com.yunbao.common.utils.RouteUtil.PATH_COIN;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.recyclerview.widget.GridLayoutManager;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import android.view.Gravity;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
@@ -21,10 +16,15 @@ import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.GridLayoutManager;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.makeramen.roundedimageview.RoundedImageView;
|
||||
import com.yunbao.common.Constants;
|
||||
import com.yunbao.common.adapter.RefreshAdapter;
|
||||
import com.yunbao.common.custom.CommonRefreshView;
|
||||
import com.yunbao.common.dialog.AbsDialogFragment;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
@@ -32,6 +32,7 @@ import com.yunbao.common.utils.DialogUitl;
|
||||
import com.yunbao.common.utils.DpUtil;
|
||||
import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.main.R;
|
||||
import com.yunbao.main.adapter.MainHomeRemFollLiveAdapter;
|
||||
import com.yunbao.main.bean.EncourageGiftBean;
|
||||
import com.yunbao.main.http.MainHttpUtil;
|
||||
|
||||
@@ -46,7 +47,7 @@ public class EncourageDialog extends AbsDialogFragment implements View.OnClickLi
|
||||
private View v_encourage, v_encourage_list, v_close;
|
||||
private ImageView img_gift1, img_gift2, img_gift3;
|
||||
private LinearLayout lt_gift1, lt_gift2, lt_gift3, lt_lt1, lt_lt2, lt_no_data;
|
||||
private RecyclerView rc_encourage;
|
||||
private CommonRefreshView rc_encourage;
|
||||
private EncourageAdapter encourageAdapter;
|
||||
private List<EncourageGiftBean> encourageList;
|
||||
private List<EncourageGiftBean> encourageList2;
|
||||
@@ -151,30 +152,68 @@ public class EncourageDialog extends AbsDialogFragment implements View.OnClickLi
|
||||
}
|
||||
|
||||
private void getDataList() {
|
||||
MainHttpUtil.getDynamicSendGiftList(id, new HttpCallback() {
|
||||
gridLayoutManager = new GridLayoutManager(getContext(), 1);
|
||||
rc_encourage.setLayoutManager(gridLayoutManager);
|
||||
lt_no_data.setVisibility(View.GONE);
|
||||
rc_encourage.setVisibility(View.VISIBLE);
|
||||
rc_encourage.setDataHelper(new CommonRefreshView.DataHelper<EncourageGiftBean>() {
|
||||
@Override
|
||||
public void onSuccess(int code, String msg, String[] info) {
|
||||
public RefreshAdapter<EncourageGiftBean> getAdapter() {
|
||||
if (encourageAdapter == null) {
|
||||
encourageAdapter = new EncourageAdapter(mContext);
|
||||
}
|
||||
return encourageAdapter;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loadData(int p, HttpCallback callback) {
|
||||
MainHttpUtil.getDynamicSendGiftList(id, p, callback);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<EncourageGiftBean> processData(String[] info) {
|
||||
if (info != null) {
|
||||
if (info.length > 0) {
|
||||
lt_no_data.setVisibility(View.GONE);
|
||||
rc_encourage.setVisibility(View.VISIBLE);
|
||||
encourageList = JSON.parseArray(Arrays.toString(info), EncourageGiftBean.class);
|
||||
|
||||
encourageAdapter = new EncourageAdapter(getContext(), encourageList);
|
||||
gridLayoutManager = new GridLayoutManager(getContext(), 1);
|
||||
rc_encourage.setLayoutManager(gridLayoutManager);
|
||||
rc_encourage.setAdapter(encourageAdapter);
|
||||
return JSON.parseArray(Arrays.toString(info), EncourageGiftBean.class);
|
||||
} else {
|
||||
lt_no_data.setVisibility(View.VISIBLE);
|
||||
rc_encourage.setVisibility(View.GONE);
|
||||
return new ArrayList<EncourageGiftBean>();
|
||||
}
|
||||
} else {
|
||||
lt_no_data.setVisibility(View.VISIBLE);
|
||||
rc_encourage.setVisibility(View.GONE);
|
||||
return new ArrayList<EncourageGiftBean>();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onRefreshSuccess(List<EncourageGiftBean> list, int listCount) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onRefreshFailure() {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoadMoreSuccess(List<EncourageGiftBean> loadItemList, int loadItemCount) {
|
||||
if (loadItemList.size() > 0)
|
||||
encourageAdapter.insertList(loadItemList);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoadMoreFailure() {
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
rc_encourage.initData();
|
||||
}
|
||||
|
||||
private void initView() {
|
||||
@@ -193,7 +232,7 @@ public class EncourageDialog extends AbsDialogFragment implements View.OnClickLi
|
||||
lt_gift3 = (LinearLayout) findViewById(R.id.lt_gift3);
|
||||
lt_lt1 = (LinearLayout) findViewById(R.id.lt_lt1);
|
||||
lt_lt2 = (LinearLayout) findViewById(R.id.lt_lt2);
|
||||
rc_encourage = (RecyclerView) findViewById(R.id.rc_encourage);
|
||||
rc_encourage = (CommonRefreshView) findViewById(R.id.rc_encourage);
|
||||
|
||||
img_gift1 = (ImageView) findViewById(R.id.img_gift1);
|
||||
img_gift2 = (ImageView) findViewById(R.id.img_gift2);
|
||||
@@ -344,16 +383,10 @@ public class EncourageDialog extends AbsDialogFragment implements View.OnClickLi
|
||||
}
|
||||
}
|
||||
|
||||
public class EncourageAdapter extends RecyclerView.Adapter<EncourageAdapter.ViewHolder> {
|
||||
private LayoutInflater mInflater;
|
||||
private List<EncourageGiftBean> mDatas;
|
||||
public class EncourageAdapter extends RefreshAdapter<EncourageGiftBean> {
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public EncourageAdapter(Context context, List<EncourageGiftBean> datats) {
|
||||
mInflater = LayoutInflater.from(context);
|
||||
mDatas = datats;
|
||||
public EncourageAdapter(Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
public class ViewHolder extends RecyclerView.ViewHolder {
|
||||
@@ -374,43 +407,24 @@ public class EncourageDialog extends AbsDialogFragment implements View.OnClickLi
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
return mDatas.size();
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建ViewHolder
|
||||
*/
|
||||
@Override
|
||||
public EncourageAdapter.ViewHolder onCreateViewHolder(ViewGroup viewGroup, int i) {
|
||||
View view;
|
||||
view = mInflater.inflate(R.layout.item_encourage_list,
|
||||
viewGroup, false);
|
||||
|
||||
EncourageAdapter.ViewHolder viewHolder = new EncourageAdapter.ViewHolder(view);
|
||||
|
||||
return viewHolder;
|
||||
return new EncourageAdapter.ViewHolder(mInflater.inflate(R.layout.item_encourage_list, viewGroup, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置值
|
||||
*/
|
||||
@Override
|
||||
public void onBindViewHolder(final EncourageAdapter.ViewHolder viewHolder, @SuppressLint("RecyclerView") final int position) {
|
||||
ImgLoader.displayAvatar(mContext, mDatas.get(position).getUser_avatar(), viewHolder.avatar);
|
||||
// LevelBean anchorLevelBean = CommonAppConfig.getInstance().getAnchorLevel(mDatas.getLevelAnchor());
|
||||
// if (anchorLevelBean != null) {
|
||||
// ImgLoader.display(mContext, CommonAppConfig.getInstance().HOST + anchorLevelBean.getThumb(), viewHolder.level_anchor);
|
||||
// }
|
||||
// LevelBean levelBean = CommonAppConfig.getInstance().getLevel(mDatas.getLevel());
|
||||
// if (levelBean != null) {
|
||||
// ImgLoader.display(mContext, levelBean.getThumb(), viewHolder.level);
|
||||
// }
|
||||
ImgLoader.display(mContext, mDatas.get(position).getGift_img(), viewHolder.tv_gift_pic);
|
||||
viewHolder.name.setText(mDatas.get(position).getUser_name());
|
||||
viewHolder.tv_gift_num.setText(mDatas.get(position).getGift_num());
|
||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder holder, int position) {
|
||||
ViewHolder viewHolder = (ViewHolder) holder;
|
||||
ImgLoader.displayAvatar(mContext, mList.get(position).getUser_avatar(), viewHolder.avatar);
|
||||
ImgLoader.display(mContext, mList.get(position).getGift_img(), viewHolder.tv_gift_pic);
|
||||
viewHolder.name.setText(mList.get(position).getUser_name());
|
||||
viewHolder.tv_gift_num.setText(mList.get(position).getGift_num());
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -692,12 +692,15 @@ public class MainHttpUtil {
|
||||
/**
|
||||
* 社区动态礼物信息列表
|
||||
*/
|
||||
public static void getDynamicSendGiftList(String id, HttpCallback callback) {
|
||||
public static void getDynamicSendGiftList(String id, int page, HttpCallback callback) {
|
||||
HttpClient.getInstance().get("Community.getDynamicSendGiftList", MainHttpConsts.GET_DYNAMICSENDGIFTLIST)
|
||||
.params("dynamic_id", id)
|
||||
.params("page", page)
|
||||
.execute(callback);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 是否是主播
|
||||
*/
|
||||
|
||||
@@ -251,10 +251,10 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
coin.setText(coins);
|
||||
}
|
||||
BigDecimal yuanbao = new BigDecimal(yuanbaos);
|
||||
String yuanbaoStr =String.valueOf(yuanbao.intValue());
|
||||
String yuanbaoStr = String.valueOf(yuanbao.intValue());
|
||||
if (yuanbaoStr.length() > 9) {
|
||||
star_coin.setText(yuanbaoStr.substring(0,yuanbaoStr.length() - 6) + "M");
|
||||
} else if (yuanbaoStr.length()>7) {
|
||||
star_coin.setText(yuanbaoStr.substring(0, yuanbaoStr.length() - 6) + "M");
|
||||
} else if (yuanbaoStr.length() > 7) {
|
||||
star_coin.setText(yuanbaoStr.substring(0, yuanbaoStr.length() - 3) + "K");
|
||||
} else {
|
||||
star_coin.setText(yuanbaos);
|
||||
@@ -326,7 +326,6 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
}
|
||||
signature.setText(singnature);
|
||||
CommonAppConfig appConfig = CommonAppConfig.getInstance();
|
||||
LevelBean anchorLevelBean = appConfig.getAnchorLevel(u.getLevelAnchor());
|
||||
|
||||
if (u.getDress().getAvatar_frame() != null) {
|
||||
if (u.getDress().getAvatar_frame().contains("svga")) {
|
||||
@@ -360,20 +359,20 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
if ("C".equals(u.getUsers_type())) {
|
||||
Constants.isAnchor = true;
|
||||
good_nub_ico.setImageResource(R.mipmap.usercard_good_nub);
|
||||
if (anchorLevelBean != null) {
|
||||
ImgLoader.display(mContext, CommonAppConfig.getInstance().HOST + anchorLevelBean.getThumb(), mLevel);
|
||||
ImgLoader.display(mContext, R.mipmap.icon_zhubolv, img_lv_pic);
|
||||
//主播等级
|
||||
tv_level.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
MobclickAgent.onEvent(mContext, "my_top_level", "个人中心最上面的等级");
|
||||
String url = CommonAppConfig.HOST + "/h5/Grade/index.html?" + "token=" + CommonAppConfig.getInstance().getToken() + "&uid=" + CommonAppConfig.getInstance().getUid() + "&for";
|
||||
ZhuangBanActivity.forward(mContext, url);
|
||||
}
|
||||
});
|
||||
tv_level.setText(anchorLevelBean.getLevel() + "");
|
||||
}
|
||||
|
||||
|
||||
ImgLoader.display(mContext, R.mipmap.icon_zhubolv, img_lv_pic);
|
||||
//主播等级
|
||||
tv_level.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
MobclickAgent.onEvent(mContext, "my_top_level", "个人中心最上面的等级");
|
||||
String url = CommonAppConfig.HOST + "/h5/Grade/index.html?" + "token=" + CommonAppConfig.getInstance().getToken() + "&uid=" + CommonAppConfig.getInstance().getUid() + "&for";
|
||||
ZhuangBanActivity.forward(mContext, url);
|
||||
}
|
||||
});
|
||||
tv_level.setText(u.getLevel() + "");
|
||||
|
||||
} else {
|
||||
Constants.isAnchor = false;
|
||||
LevelBean levelBean = appConfig.getLevel(u.getLevel());
|
||||
|
||||
@@ -23,11 +23,13 @@ import com.yunbao.common.Constants;
|
||||
import com.yunbao.common.activity.WebViewActivity;
|
||||
import com.yunbao.common.bean.GoogleBean;
|
||||
import com.yunbao.common.bean.LevelBean;
|
||||
import com.yunbao.common.bean.NewLevelModel;
|
||||
import com.yunbao.common.bean.UserBean;
|
||||
import com.yunbao.common.bean.UserItemBean;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.interfaces.CommonCallback;
|
||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||
import com.yunbao.common.manager.NewLevelManager;
|
||||
import com.yunbao.common.utils.RouteUtil;
|
||||
import com.yunbao.common.utils.SVGAViewUtils;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
@@ -77,7 +79,7 @@ public class MainMeViewHolder1 extends AbsMainViewHolder implements OnItemClickL
|
||||
private View v_noble;
|
||||
// private LinearLayout btnUserNoble;
|
||||
private ImageView user_noble_ico, good_nub_ico;
|
||||
private TextView user_noble_text;
|
||||
private TextView user_noble_text,leave;
|
||||
private UserItemBean beanStetting = null, beanKefu = null;
|
||||
private boolean firstInto = true;
|
||||
|
||||
@@ -124,6 +126,7 @@ public class MainMeViewHolder1 extends AbsMainViewHolder implements OnItemClickL
|
||||
btnCopy = (TextView) findViewById(R.id.btn_copy);
|
||||
// btnUserNoble = (LinearLayout) findViewById(R.id.btn_user_noble);
|
||||
user_noble_text = (TextView) findViewById(R.id.user_noble_text);
|
||||
leave = (TextView) findViewById(R.id.leave);
|
||||
|
||||
img_kefu = (ImageView) findViewById(R.id.img_kefu);
|
||||
img_setting = (ImageView) findViewById(R.id.img_setting);
|
||||
@@ -258,7 +261,7 @@ public class MainMeViewHolder1 extends AbsMainViewHolder implements OnItemClickL
|
||||
gold.setText(u.getCoin());
|
||||
signature.setText(u.getSignature());
|
||||
CommonAppConfig appConfig = CommonAppConfig.getInstance();
|
||||
LevelBean anchorLevelBean = appConfig.getAnchorLevel(u.getLevelAnchor());
|
||||
|
||||
|
||||
if (u.getDress().getAvatar_frame() != null) {
|
||||
if (u.getDress().getAvatar_frame().contains("svga")) {
|
||||
@@ -290,9 +293,20 @@ public class MainMeViewHolder1 extends AbsMainViewHolder implements OnItemClickL
|
||||
user_noble_ico.setImageResource(R.mipmap.df_nobe);
|
||||
}
|
||||
|
||||
if (anchorLevelBean != null) {
|
||||
ImgLoader.display(mContext, CommonAppConfig.getInstance().HOST + anchorLevelBean.getThumb(), mLevelAnchor);
|
||||
}
|
||||
List<NewLevelModel> models = new NewLevelManager(mContext).getNewAnchorLevelModels();
|
||||
int anchorLevel = 0;
|
||||
|
||||
|
||||
anchorLevel = u.getLevelAnchor();
|
||||
String imgUrl = "";
|
||||
for (NewLevelModel newLevelModel : models) {
|
||||
if (newLevelModel.getLeveMin() <= anchorLevel && anchorLevel <= newLevelModel.getLeveMax()) {
|
||||
imgUrl = newLevelModel.getThumb();
|
||||
}
|
||||
}
|
||||
leave.setText(String.valueOf(u.getLevelAnchor()));
|
||||
ImgLoader.display(mContext, imgUrl, mLevelAnchor);
|
||||
|
||||
LevelBean levelBean = appConfig.getLevel(u.getLevel());
|
||||
if (levelBean != null) {
|
||||
ImgLoader.display(mContext, levelBean.getThumb(), mLevel);
|
||||
|
||||
@@ -4,9 +4,6 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.drawable.ColorDrawable;
|
||||
import com.google.android.material.appbar.AppBarLayout;
|
||||
import androidx.core.content.ContextCompat;
|
||||
import androidx.viewpager.widget.ViewPager;
|
||||
import android.text.TextUtils;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
@@ -16,24 +13,29 @@ import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.core.content.ContextCompat;
|
||||
import androidx.viewpager.widget.ViewPager;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.google.android.material.appbar.AppBarLayout;
|
||||
import com.yunbao.common.CommonAppConfig;
|
||||
import com.yunbao.common.Constants;
|
||||
import com.yunbao.common.activity.AbsActivity;
|
||||
import com.yunbao.common.adapter.ViewPagerAdapter;
|
||||
import com.yunbao.common.bean.LevelBean;
|
||||
import com.yunbao.common.bean.NewLevelModel;
|
||||
import com.yunbao.common.bean.UserBean;
|
||||
import com.yunbao.common.event.FollowEvent;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.CommonHttpConsts;
|
||||
import com.yunbao.common.http.CommonHttpUtil;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
import com.yunbao.common.manager.NewLevelManager;
|
||||
import com.yunbao.common.utils.CommonIconUtil;
|
||||
import com.yunbao.common.utils.DpUtil;
|
||||
import com.yunbao.common.utils.StringUtil;
|
||||
import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
import com.yunbao.live.activity.LiveContributeActivity;
|
||||
import com.yunbao.live.activity.LiveGuardListActivity;
|
||||
import com.yunbao.live.activity.SystemMessageActivity;
|
||||
@@ -87,7 +89,7 @@ public class UserHomeViewHolder extends AbsLivePageViewHolder implements AppBarL
|
||||
private AppBarLayout mAppBarLayout;
|
||||
private ImageView mAvatarBg;
|
||||
private ImageView mAvatar;
|
||||
private TextView mName;
|
||||
private TextView mName, leave;
|
||||
private ImageView mSex;
|
||||
private ImageView mLevelAnchor;
|
||||
private ImageView mLevel;
|
||||
@@ -158,6 +160,7 @@ public class UserHomeViewHolder extends AbsLivePageViewHolder implements AppBarL
|
||||
mAvatarBg = (ImageView) findViewById(R.id.bg_avatar);
|
||||
mAvatar = (ImageView) findViewById(R.id.avatar);
|
||||
mName = (TextView) findViewById(R.id.name);
|
||||
leave = (TextView) findViewById(R.id.leave);
|
||||
mSex = (ImageView) findViewById(R.id.sex);
|
||||
mLevelAnchor = (ImageView) findViewById(R.id.level_anchor);
|
||||
mLevel = (ImageView) findViewById(R.id.level);
|
||||
@@ -205,8 +208,8 @@ public class UserHomeViewHolder extends AbsLivePageViewHolder implements AppBarL
|
||||
}
|
||||
});
|
||||
|
||||
mVideoString =mContext.getString(R.string.video);
|
||||
mLiveString =mContext.getString(R.string.live);
|
||||
mVideoString = mContext.getString(R.string.video);
|
||||
mLiveString = mContext.getString(R.string.live);
|
||||
mIndicator = (MagicIndicator) findViewById(R.id.indicator);
|
||||
final String[] titles = new String[]{mVideoString, mLiveString};
|
||||
CommonNavigator commonNavigator = new CommonNavigator(mContext);
|
||||
@@ -354,15 +357,26 @@ public class UserHomeViewHolder extends AbsLivePageViewHolder implements AppBarL
|
||||
mTitleView.setText(toName);
|
||||
mSex.setImageResource(CommonIconUtil.getSexIcon(userBean.getSex()));
|
||||
CommonAppConfig appConfig = CommonAppConfig.getInstance();
|
||||
LevelBean levelAnchor = appConfig.getAnchorLevel(userBean.getLevelAnchor());
|
||||
ImgLoader.display(mContext, levelAnchor.getThumb(), mLevelAnchor);
|
||||
List<NewLevelModel> models = new NewLevelManager(mContext).getNewAnchorLevelModels();
|
||||
int anchorLevel = 0;
|
||||
anchorLevel = userBean.getLevelAnchor();
|
||||
String imgUrl = "";
|
||||
for (NewLevelModel newLevelModel : models) {
|
||||
if (newLevelModel.getLeveMin() <= anchorLevel && anchorLevel <= newLevelModel.getLeveMax()) {
|
||||
imgUrl = newLevelModel.getThumb();
|
||||
}
|
||||
}
|
||||
leave.setText(String.valueOf(anchorLevel));
|
||||
ImgLoader.display(mContext, imgUrl, mLevelAnchor);
|
||||
|
||||
|
||||
LevelBean level = appConfig.getLevel(userBean.getLevel());
|
||||
ImgLoader.display(mContext, level.getThumb(), mLevel);
|
||||
|
||||
mID.setText(userBean.getLiangNameTip());
|
||||
String fansNum = StringUtil.toWan(userBean.getFans());
|
||||
mBtnFans.setText(fansNum + " " +mContext.getString(R.string.fans));
|
||||
mBtnFollow.setText(StringUtil.toWan(userBean.getFollows()) + " " +mContext.getString(R.string.follow));
|
||||
mBtnFans.setText(fansNum + " " + mContext.getString(R.string.fans));
|
||||
mBtnFollow.setText(StringUtil.toWan(userBean.getFollows()) + " " + mContext.getString(R.string.follow));
|
||||
mSign.setText(userBean.getSignature());
|
||||
mBtnFollow2.setText(obj.getIntValue("isattention") == 1 ? R.string.following : R.string.follow);
|
||||
mBtnBlack.setText(obj.getIntValue("isblack") == 1 ? R.string.black_ing : R.string.black);
|
||||
@@ -374,7 +388,7 @@ public class UserHomeViewHolder extends AbsLivePageViewHolder implements AppBarL
|
||||
mLiveCountTextView.setText(mLiveString + " " + obj.getString("livenums"));
|
||||
}
|
||||
showImpress(obj.getString("label"));
|
||||
mVotesName.setText(appConfig.getVotesName() +mContext.getString(R.string.live_user_home_con));
|
||||
mVotesName.setText(appConfig.getVotesName() + mContext.getString(R.string.live_user_home_con));
|
||||
mUserHomeSharePresenter.setToUid(mToUid).setToName(toName).setAvatarThumb(userBean.getAvatarThumb()).setFansNum(fansNum);
|
||||
showContribute(obj.getString("contribute"));
|
||||
showGuardList(obj.getString("guardlist"));
|
||||
@@ -396,7 +410,7 @@ public class UserHomeViewHolder extends AbsLivePageViewHolder implements AppBarL
|
||||
}
|
||||
if (!mSelf) {
|
||||
ImpressBean lastBean = new ImpressBean();
|
||||
lastBean.setName("+ " +mContext.getString(R.string.impress_add));
|
||||
lastBean.setName("+ " + mContext.getString(R.string.impress_add));
|
||||
lastBean.setColor("#ffdd00");
|
||||
list.add(lastBean);
|
||||
} else {
|
||||
|
||||
@@ -35,15 +35,21 @@ import com.yunbao.common.adapter.ViewPagerAdapter;
|
||||
import com.yunbao.common.bean.ConfigBean;
|
||||
import com.yunbao.common.bean.LevelBean;
|
||||
import com.yunbao.common.bean.LiveBean;
|
||||
import com.yunbao.common.bean.NewLevelModel;
|
||||
import com.yunbao.common.event.FollowEvent;
|
||||
import com.yunbao.common.event.LiveRoomChangeEvent;
|
||||
import com.yunbao.common.event.UpdateFieldEvent;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.CommonHttpConsts;
|
||||
import com.yunbao.common.http.CommonHttpUtil;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
import com.yunbao.common.http.LiveHttpConsts;
|
||||
import com.yunbao.common.http.LiveHttpUtil;
|
||||
import com.yunbao.common.manager.NewLevelManager;
|
||||
import com.yunbao.common.utils.CommonIconUtil;
|
||||
import com.yunbao.common.utils.DialogUitl;
|
||||
import com.yunbao.common.utils.DpUtil;
|
||||
import com.yunbao.common.utils.LiveRoomCheckLivePresenter;
|
||||
import com.yunbao.common.utils.MicStatusManager;
|
||||
import com.yunbao.common.utils.RouteUtil;
|
||||
import com.yunbao.common.utils.SVGAViewUtils;
|
||||
@@ -52,10 +58,6 @@ import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.live.activity.LiveReportActivity;
|
||||
import com.yunbao.live.bean.SearchUserBean;
|
||||
import com.yunbao.live.dialog.LiveShareDialogFragment;
|
||||
import com.yunbao.common.event.LiveRoomChangeEvent;
|
||||
import com.yunbao.common.http.LiveHttpConsts;
|
||||
import com.yunbao.common.http.LiveHttpUtil;
|
||||
import com.yunbao.common.utils.LiveRoomCheckLivePresenter;
|
||||
import com.yunbao.live.presenter.UserHomeSharePresenter;
|
||||
import com.yunbao.live.views.AbsLivePageViewHolder;
|
||||
import com.yunbao.live.views.AbsUserHomeViewHolder;
|
||||
@@ -112,7 +114,7 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
private ImageView mLevel;
|
||||
private TextView mID;
|
||||
private View mBtnLive;
|
||||
private TextView mBtnFans;
|
||||
private TextView mBtnFans , leave;;
|
||||
private TextView mBtnFollow;
|
||||
private ImageView mFollowImage;
|
||||
private int isblack;
|
||||
@@ -166,7 +168,7 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
}
|
||||
|
||||
|
||||
String s =mContext.getString(R.string.black);
|
||||
String s = mContext.getString(R.string.black);
|
||||
|
||||
@Override
|
||||
public void init() {
|
||||
@@ -266,6 +268,7 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
mID = (TextView) findViewById(R.id.id_val);
|
||||
good_nub_ico = (ImageView) findViewById(R.id.good_nub_ico);
|
||||
mBtnFans = (TextView) findViewById(R.id.btn_fans);
|
||||
leave = (TextView) findViewById(R.id.leave);
|
||||
mBtnFollow = (TextView) findViewById(R.id.btn_follow);
|
||||
gift_svga = (SVGAImageView) findViewById(com.yunbao.live.R.id.gift_svga);
|
||||
mAvatar = (ImageView) findViewById(R.id.avatar);
|
||||
@@ -316,8 +319,8 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
}
|
||||
});
|
||||
|
||||
mVideoString =mContext.getString(R.string.video);
|
||||
mLiveString =mContext.getString(R.string.honor);
|
||||
mVideoString = mContext.getString(R.string.video);
|
||||
mLiveString = mContext.getString(R.string.honor);
|
||||
mIndicator = (MagicIndicator) findViewById(R.id.indicator);
|
||||
final String[] titles = new String[]{mContext.getString(R.string.live_user_home_detail), mLiveString, mVideoString,};
|
||||
// final String[] titles = new String[]{mContext.getString(R.string.live_user_home_detail), mVideoString}; //mxj update 2019-9-19
|
||||
@@ -500,9 +503,20 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
mName.setText(toName);
|
||||
mSex.setImageResource(CommonIconUtil.getSexIcon(userBean.getSex()));
|
||||
CommonAppConfig appConfig = CommonAppConfig.getInstance();
|
||||
LevelBean levelAnchor = appConfig.getAnchorLevel(userBean.getLevelAnchor());
|
||||
Log.i("Tag", CommonAppConfig.getInstance().HOST + levelAnchor.getThumb());
|
||||
ImgLoader.display(mContext, CommonAppConfig.getInstance().HOST + levelAnchor.getThumb(), mLevelAnchor);
|
||||
|
||||
List<NewLevelModel> models = new NewLevelManager(mContext).getNewAnchorLevelModels();
|
||||
int anchorLevel = 0;
|
||||
|
||||
anchorLevel = userBean.getLevelAnchor();
|
||||
String imgUrl = "";
|
||||
for (NewLevelModel newLevelModel : models) {
|
||||
if (newLevelModel.getLeveMin() <= anchorLevel && anchorLevel <= newLevelModel.getLeveMax()) {
|
||||
imgUrl = newLevelModel.getThumb();
|
||||
}
|
||||
}
|
||||
leave.setText(String.valueOf(userBean.getLevelAnchor()));
|
||||
ImgLoader.display(mContext, imgUrl, mLevelAnchor);
|
||||
|
||||
LevelBean level = appConfig.getLevel(userBean.getLevel());
|
||||
ImgLoader.display(mContext, level.getThumb(), mLevel);
|
||||
//修改靓号图标 个人中心子页面
|
||||
@@ -515,8 +529,8 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
}
|
||||
// mID.setText(" "+userBean.getLiangNameTip());
|
||||
String fansNum = StringUtil.toWan(userBean.getFans());
|
||||
mBtnFans.setText(fansNum + " " +mContext.getString(R.string.fans));
|
||||
mBtnFollow.setText(StringUtil.toWan(userBean.getFollows()) + " " +mContext.getString(R.string.follow));
|
||||
mBtnFans.setText(fansNum + " " + mContext.getString(R.string.fans));
|
||||
mBtnFollow.setText(StringUtil.toWan(userBean.getFollows()) + " " + mContext.getString(R.string.follow));
|
||||
|
||||
if (obj.getIntValue("isattention") == 1) {
|
||||
if (mFollowImage != null) {
|
||||
@@ -774,7 +788,7 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
public void onLiveRoomChanged(String liveUid, String stream, int liveType, String liveTypeVal, String liveSdk) {
|
||||
|
||||
if (mFromLiveRoom) {
|
||||
if(MicStatusManager.getInstance().isMic(liveUid)){
|
||||
if (MicStatusManager.getInstance().isMic(liveUid)) {
|
||||
MicStatusManager.getInstance().showDownMicDialog(mContext);
|
||||
return;
|
||||
}
|
||||
@@ -864,8 +878,8 @@ public class UserHomeViewHolder2 extends AbsLivePageViewHolder implements LiveSh
|
||||
mSex.setImageResource(CommonIconUtil.getSexIcon(userBean.getSex()));
|
||||
mID.setText(userBean.getLiangNameTip());
|
||||
String fansNum = StringUtil.toWan(userBean.getFans());
|
||||
mBtnFans.setText(fansNum + " " +mContext.getString(R.string.fans));
|
||||
mBtnFollow.setText(StringUtil.toWan(userBean.getFollows()) + " " +mContext.getString(R.string.follow));
|
||||
mBtnFans.setText(fansNum + " " + mContext.getString(R.string.fans));
|
||||
mBtnFollow.setText(StringUtil.toWan(userBean.getFollows()) + " " + mContext.getString(R.string.follow));
|
||||
if (mDetailViewHolder != null) {
|
||||
mDetailViewHolder.refreshData(userBean, obj);
|
||||
}
|
||||
|
||||
@@ -406,7 +406,7 @@
|
||||
android:orientation="vertical"
|
||||
android:visibility="visible">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
<com.yunbao.common.custom.CommonRefreshView
|
||||
android:id="@+id/rc_encourage"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp"
|
||||
android:paddingLeft="15dp"
|
||||
android:paddingRight="15dp"
|
||||
>
|
||||
android:paddingRight="15dp">
|
||||
|
||||
<com.makeramen.roundedimageview.RoundedImageView
|
||||
android:id="@+id/avatar"
|
||||
@@ -15,8 +13,7 @@
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginRight="15dp"
|
||||
android:scaleType="centerCrop"
|
||||
app:riv_oval="true"
|
||||
/>
|
||||
app:riv_oval="true" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/name"
|
||||
@@ -28,8 +25,7 @@
|
||||
android:maxWidth="130dp"
|
||||
android:singleLine="true"
|
||||
android:textColor="@color/textColor"
|
||||
android:textSize="16sp"
|
||||
/>
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/sign"
|
||||
@@ -41,17 +37,16 @@
|
||||
android:ellipsize="end"
|
||||
android:singleLine="true"
|
||||
android:textColor="@color/gray3"
|
||||
android:textSize="14sp"
|
||||
/>
|
||||
android:textSize="14sp" />
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_toRightOf="@id/name"
|
||||
android:layout_alignTop="@id/name"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginTop="3dp"
|
||||
android:layout_toRightOf="@id/name"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
@@ -59,18 +54,33 @@
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="15dp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_marginLeft="5dp"/>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/leave"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="28dp"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="10sp"
|
||||
android:textStyle="bold" />
|
||||
</FrameLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_marginLeft="5dp"
|
||||
/>
|
||||
android:layout_marginLeft="5dp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -86,23 +96,21 @@
|
||||
android:gravity="center"
|
||||
android:textColor="@color/fg_btn_follow"
|
||||
android:textSize="11sp"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
android:visibility="gone" />
|
||||
|
||||
|
||||
<pl.droidsonroids.gif.GifImageView
|
||||
android:id="@+id/btn_live"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:src="@mipmap/icon_user_home_living"/>
|
||||
android:adjustViewBounds="true"
|
||||
android:src="@mipmap/icon_user_home_living"
|
||||
android:visibility="gone" />
|
||||
|
||||
<View
|
||||
style="@style/line2"
|
||||
android:layout_alignParentBottom="true"
|
||||
/>
|
||||
android:layout_alignParentBottom="true" />
|
||||
|
||||
</RelativeLayout>
|
||||
@@ -1,28 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
>
|
||||
android:background="@color/white">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/bottom"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="46dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
>
|
||||
android:layout_alignParentBottom="true">
|
||||
|
||||
<View
|
||||
style="@style/line2"
|
||||
/>
|
||||
<View style="@style/line2" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal"
|
||||
>
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/btn_follow_2"
|
||||
@@ -33,16 +27,14 @@
|
||||
android:text="@string/follow"
|
||||
android:textColor="@color/textColor2"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
<View
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:background="@color/gray2"
|
||||
/>
|
||||
android:layout_marginBottom="10dp"
|
||||
android:background="@color/gray2" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/btn_pri_msg"
|
||||
@@ -53,16 +45,14 @@
|
||||
android:text="@string/pri_msg"
|
||||
android:textColor="@color/textColor2"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
<View
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:background="@color/gray2"
|
||||
/>
|
||||
android:layout_marginBottom="10dp"
|
||||
android:background="@color/gray2" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/btn_black"
|
||||
@@ -73,8 +63,7 @@
|
||||
android:text="@string/black"
|
||||
android:textColor="@color/textColor2"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
@@ -82,8 +71,7 @@
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_above="@id/bottom"
|
||||
>
|
||||
android:layout_above="@id/bottom">
|
||||
|
||||
<com.google.android.material.appbar.AppBarLayout
|
||||
android:id="@+id/appBarLayout"
|
||||
@@ -92,45 +80,39 @@
|
||||
android:background="@color/transparent"
|
||||
android:fadingEdge="none"
|
||||
app:elevation="0dp"
|
||||
app:layout_behavior="com.yunbao.common.custom.FixAppBarLayoutBehavior"
|
||||
>
|
||||
app:layout_behavior="com.yunbao.common.custom.FixAppBarLayoutBehavior">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:minHeight="65dp"
|
||||
android:orientation="vertical"
|
||||
app:layout_scrollFlags="scroll|exitUntilCollapsed"
|
||||
>
|
||||
app:layout_scrollFlags="scroll|exitUntilCollapsed">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="220dp"
|
||||
>
|
||||
android:layout_height="220dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/bg_avatar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:scaleType="centerCrop"
|
||||
/>
|
||||
android:scaleType="centerCrop" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="#b3000000"
|
||||
/>
|
||||
android:background="#b3000000" />
|
||||
|
||||
<com.makeramen.roundedimageview.RoundedImageView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="70dp"
|
||||
android:layout_height="70dp"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginRight="20dp"
|
||||
android:layout_marginTop="70dp"
|
||||
android:layout_marginRight="20dp"
|
||||
android:scaleType="centerCrop"
|
||||
app:riv_oval="true"
|
||||
/>
|
||||
app:riv_oval="true" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/name"
|
||||
@@ -140,35 +122,48 @@
|
||||
android:layout_toRightOf="@id/avatar"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="20sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/sex"
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_below="@id/name"
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_toRightOf="@id/avatar"
|
||||
/>
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_toRightOf="@id/avatar" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="15dp"
|
||||
<FrameLayout
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp"
|
||||
android:layout_alignTop="@id/sex"
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_toRightOf="@id/sex"
|
||||
/>
|
||||
android:layout_toRightOf="@id/sex">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/leave"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="28dp"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="10sp"
|
||||
android:textStyle="bold" />
|
||||
</FrameLayout>
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_alignTop="@id/sex"
|
||||
android:layout_toRightOf="@id/level_anchor"
|
||||
/>
|
||||
android:layout_toRightOf="@id/level_anchor" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/id_val"
|
||||
@@ -178,8 +173,7 @@
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_toRightOf="@id/avatar"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
/>
|
||||
android:textSize="14sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/btn_fans"
|
||||
@@ -189,21 +183,19 @@
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
/>
|
||||
android:textSize="14sp" />
|
||||
|
||||
<View
|
||||
android:id="@+id/line"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="12dp"
|
||||
android:layout_alignTop="@id/btn_fans"
|
||||
android:layout_below="@id/avatar"
|
||||
android:layout_alignTop="@id/btn_fans"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:layout_marginTop="3dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:layout_toRightOf="@id/btn_fans"
|
||||
android:background="@color/white"
|
||||
/>
|
||||
android:background="@color/white" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/btn_follow"
|
||||
@@ -212,8 +204,7 @@
|
||||
android:layout_alignTop="@id/btn_fans"
|
||||
android:layout_toRightOf="@id/line"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
/>
|
||||
android:textSize="14sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/sign"
|
||||
@@ -221,38 +212,34 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/btn_fans"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:layout_marginTop="12dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:singleLine="true"
|
||||
android:textColor="#fff"
|
||||
android:textSize="14sp"
|
||||
/>
|
||||
android:textSize="14sp" />
|
||||
</RelativeLayout>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:text="@string/impress"
|
||||
android:textColor="@color/textColor2"
|
||||
android:textSize="15dp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="34dp"
|
||||
android:layout_marginLeft="15dp"
|
||||
>
|
||||
android:layout_marginLeft="15dp">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/impress_group"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal"
|
||||
/>
|
||||
android:orientation="horizontal" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/no_impress_tip"
|
||||
@@ -262,16 +249,14 @@
|
||||
android:text="@string/impress_tip_3"
|
||||
android:textColor="@color/gray3"
|
||||
android:textSize="14sp"
|
||||
android:visibility="invisible"
|
||||
/>
|
||||
android:visibility="invisible" />
|
||||
</FrameLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:background="@color/gray2"
|
||||
/>
|
||||
android:background="@color/gray2" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/con_group_wrap"
|
||||
@@ -280,14 +265,12 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingLeft="15dp"
|
||||
android:paddingRight="15dp"
|
||||
>
|
||||
android:paddingRight="15dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="18dp"
|
||||
android:src="@mipmap/icon_live_user_home_1"
|
||||
/>
|
||||
android:src="@mipmap/icon_live_user_home_1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/votes_name"
|
||||
@@ -295,8 +278,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="8dp"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
|
||||
<LinearLayout
|
||||
@@ -307,21 +289,17 @@
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="right"
|
||||
android:orientation="horizontal"
|
||||
/>
|
||||
android:orientation="horizontal" />
|
||||
|
||||
|
||||
<ImageView
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="18dp"
|
||||
android:src="@mipmap/icon_arrow_right"
|
||||
/>
|
||||
android:src="@mipmap/icon_arrow_right" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
style="@style/line2"
|
||||
/>
|
||||
<View style="@style/line2" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/guard_group_wrap"
|
||||
@@ -330,14 +308,12 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingLeft="15dp"
|
||||
android:paddingRight="15dp"
|
||||
>
|
||||
android:paddingRight="15dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="18dp"
|
||||
android:src="@mipmap/icon_live_user_home_2"
|
||||
/>
|
||||
android:src="@mipmap/icon_live_user_home_2" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
@@ -345,8 +321,7 @@
|
||||
android:layout_marginLeft="8dp"
|
||||
android:text="@string/guard_list"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/guard_group"
|
||||
@@ -356,14 +331,12 @@
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="right"
|
||||
android:orientation="horizontal"
|
||||
/>
|
||||
android:orientation="horizontal" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="18dp"
|
||||
android:src="@mipmap/icon_arrow_right"
|
||||
/>
|
||||
android:src="@mipmap/icon_arrow_right" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -372,14 +345,12 @@
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
android:orientation="vertical">
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:background="@color/gray2"
|
||||
/>
|
||||
android:background="@color/gray2" />
|
||||
|
||||
|
||||
<net.lucode.hackware.magicindicator.MagicIndicator
|
||||
@@ -387,13 +358,10 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="33dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:layout_marginTop="5dp"
|
||||
/>
|
||||
android:layout_marginBottom="5dp" />
|
||||
|
||||
<View
|
||||
style="@style/line2"
|
||||
/>
|
||||
<View style="@style/line2" />
|
||||
|
||||
</LinearLayout>
|
||||
</com.google.android.material.appbar.AppBarLayout>
|
||||
@@ -403,8 +371,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:overScrollMode="never"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior"
|
||||
/>
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
|
||||
@@ -412,8 +379,7 @@
|
||||
android:id="@+id/top"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="65dp"
|
||||
android:clickable="true"
|
||||
>
|
||||
android:clickable="true">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/titleView"
|
||||
@@ -425,8 +391,7 @@
|
||||
android:paddingTop="30dp"
|
||||
android:textColor="@color/textColor"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold"
|
||||
/>
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/btn_back"
|
||||
@@ -436,20 +401,18 @@
|
||||
android:layout_marginBottom="3dp"
|
||||
android:padding="9dp"
|
||||
android:src="@mipmap/icon_back"
|
||||
android:tint="@color/white"
|
||||
/>
|
||||
android:tint="@color/white" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/btn_share"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="3dp"
|
||||
android:padding="8dp"
|
||||
android:src="@mipmap/icon_user_home_share"
|
||||
android:tint="@color/white"
|
||||
/>
|
||||
android:tint="@color/white" />
|
||||
</RelativeLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
@@ -219,10 +219,27 @@
|
||||
android:gravity="bottom"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="15dp" />
|
||||
<FrameLayout
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/leave"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="28dp"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="10sp"
|
||||
android:textStyle="bold" />
|
||||
</FrameLayout>
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level"
|
||||
|
||||
@@ -126,12 +126,30 @@
|
||||
android:layout_height="15dp"
|
||||
android:src="@mipmap/icon_userlv" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="15dp"
|
||||
<FrameLayout
|
||||
android:id="@+id/level_anchor_la"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:visibility="gone" />
|
||||
android:visibility="gone">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level_anchor"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="19dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/leave"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="28dp"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="10sp"
|
||||
android:textStyle="bold" />
|
||||
</FrameLayout>
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/level"
|
||||
|
||||
Reference in New Issue
Block a user