1.feat : 房间用户资料卡片 , 初次提交
This commit is contained in:
6
app/src/common/res/drawable/bg_000000_topr16.xml
Normal file
6
app/src/common/res/drawable/bg_000000_topr16.xml
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="16dp" />
|
||||
<solid android:color="#000000"/>
|
||||
</shape>
|
6
app/src/common/res/drawable/bg_ffffff_r16.xml
Normal file
6
app/src/common/res/drawable/bg_ffffff_r16.xml
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="16dp" />
|
||||
<solid android:color="#ffffff"/>
|
||||
</shape>
|
@@ -156,12 +156,12 @@ public class ButtonItemFactory {
|
||||
}
|
||||
}
|
||||
// 私聊
|
||||
buttonItems.add(createPrivateChatItem(context, account, isInRoom));
|
||||
// buttonItems.add(createPrivateChatItem(context, account, isInRoom));
|
||||
|
||||
//关注
|
||||
buttonItems.add(createAttentItem());
|
||||
//关注
|
||||
buttonItems.add(createAtItem());
|
||||
// buttonItems.add(createAttentItem());
|
||||
//aite @
|
||||
// buttonItems.add(createAtItem());
|
||||
|
||||
final RoomInfo currentRoom = AvRoomDataManager.get().mCurrentRoomInfo;
|
||||
if (currentRoom == null) return buttonItems;
|
||||
@@ -475,28 +475,28 @@ public class ButtonItemFactory {
|
||||
return new ButtonItem(ResUtil.getString(R.string.erban_avroom_buttonitemfactory_036), () -> UIHelper.showReportPage(context, uid, reportType));
|
||||
}
|
||||
|
||||
public static List<ViewItem> createMiniWorldGroupButtonItems(
|
||||
Context context,
|
||||
long uid,
|
||||
boolean isInRoom,
|
||||
GiftDialog.OnGiftDialogBtnClickListener listener) {
|
||||
if (uid <= 0) return null;
|
||||
String currentUid = String.valueOf(AuthModel.get().getCurrentUid());
|
||||
String account = String.valueOf(uid);
|
||||
//account和chatRoomMember 不会同时为空,如果同时为空,则是前面传参出错
|
||||
boolean isMySelf = Objects.equals(currentUid, account);
|
||||
if (isMySelf) {
|
||||
return null;
|
||||
}
|
||||
List<ViewItem> buttonItems = new ArrayList<>();
|
||||
//不在房间内,也不需要魔法
|
||||
buttonItems.add(createSendGiftItem(context, uid, true, true, listener));
|
||||
// 私聊
|
||||
buttonItems.add(createPrivateChatItem(context, account, isInRoom));
|
||||
//装扮和关注目前是都有的操作
|
||||
// buttonItems.add(createSendDecorationItem(context, uid));
|
||||
buttonItems.add(createAttentItem());
|
||||
buttonItems.add(createFindMeItem());
|
||||
return buttonItems;
|
||||
}
|
||||
// public static List<ViewItem> createMiniWorldGroupButtonItems(
|
||||
// Context context,
|
||||
// long uid,
|
||||
// boolean isInRoom,
|
||||
// GiftDialog.OnGiftDialogBtnClickListener listener) {
|
||||
// if (uid <= 0) return null;
|
||||
// String currentUid = String.valueOf(AuthModel.get().getCurrentUid());
|
||||
// String account = String.valueOf(uid);
|
||||
// //account和chatRoomMember 不会同时为空,如果同时为空,则是前面传参出错
|
||||
// boolean isMySelf = Objects.equals(currentUid, account);
|
||||
// if (isMySelf) {
|
||||
// return null;
|
||||
// }
|
||||
// List<ViewItem> buttonItems = new ArrayList<>();
|
||||
// //不在房间内,也不需要魔法
|
||||
// buttonItems.add(createSendGiftItem(context, uid, true, true, listener));
|
||||
// // 私聊
|
||||
// buttonItems.add(createPrivateChatItem(context, account, isInRoom));
|
||||
// //装扮和关注目前是都有的操作
|
||||
// // buttonItems.add(createSendDecorationItem(context, uid));
|
||||
// buttonItems.add(createAttentItem());
|
||||
// buttonItems.add(createFindMeItem());
|
||||
// return buttonItems;
|
||||
// }
|
||||
}
|
||||
|
@@ -45,6 +45,10 @@ public class UpMicAdapter extends BaseQuickAdapter<String, BaseViewHolder> {
|
||||
size = 4;
|
||||
} else if (AvRoomDataManager.get().isOpenGame()) {
|
||||
size = 6;
|
||||
} else if (AvRoomDataManager.get().isPartyRoom()) {
|
||||
size = 10;
|
||||
} else if (AvRoomDataManager.get().isRevelryRoom()) {
|
||||
size = 15;
|
||||
} else {
|
||||
size = 9;
|
||||
}
|
||||
@@ -62,6 +66,7 @@ public class UpMicAdapter extends BaseQuickAdapter<String, BaseViewHolder> {
|
||||
if (roomQueueInfo == null) return;
|
||||
|
||||
ImageView imageView = helper.getView(R.id.iv_mic);
|
||||
//todo do 19麦房间时 老板麦位特殊特殊图标 待更换
|
||||
//麦上没人,且不是离开模式房主位,相亲模式的管理才能上房主位
|
||||
if (roomQueueInfo.mChatRoomMember == null &&
|
||||
(!AvRoomDataManager.get().isLeaveMode() || position != 0) &&
|
||||
|
@@ -36,6 +36,7 @@ import com.chwl.app.ui.relation.FansListActivity
|
||||
import com.chwl.app.ui.utils.ImageLoadUtils
|
||||
import com.chwl.app.ui.wallet.WalletActivity
|
||||
import com.chwl.app.ui.webview.CommonWebViewActivity
|
||||
import com.chwl.app.ui.widget.UserInfoDialog
|
||||
import com.chwl.app.utils.HomeUIManager
|
||||
import com.chwl.app.view.GenderAgeTextView
|
||||
import com.chwl.app.vip.VipCenterActivity
|
||||
@@ -386,6 +387,11 @@ class MeFragment : BaseFragment(), View.OnClickListener {
|
||||
// view.loadUrl(url);
|
||||
|
||||
|
||||
UserInfoDialog.showNewUserInfoDialog(
|
||||
mContext,
|
||||
AuthModel.get().currentUid
|
||||
)
|
||||
|
||||
"特斯特特斯特".doLog()
|
||||
// LogUtil.d("特斯特特斯特")
|
||||
|
||||
|
110
app/src/main/java/com/chwl/app/ui/widget/MicSelectDialog.kt
Normal file
110
app/src/main/java/com/chwl/app/ui/widget/MicSelectDialog.kt
Normal file
@@ -0,0 +1,110 @@
|
||||
package com.chwl.app.ui.widget
|
||||
|
||||
import android.view.Gravity
|
||||
import android.view.WindowManager
|
||||
import androidx.recyclerview.widget.GridLayoutManager
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.chwl.app.R
|
||||
import com.chwl.app.avroom.adapter.UpMicAdapter
|
||||
import com.chwl.app.base.BaseDialogFragment
|
||||
import com.chwl.app.databinding.DialogMicSelectBinding
|
||||
import com.chwl.core.auth.AuthModel
|
||||
import com.chwl.core.manager.AvRoomDataManager
|
||||
import com.chwl.core.manager.IMNetEaseManager
|
||||
import com.chwl.core.room.giftvalue.helper.GiftValueMrg
|
||||
import com.chwl.core.room.model.HomePartyModel
|
||||
import com.chwl.core.user.bean.BaseInfo
|
||||
import com.chwl.core.user.bean.UserInfo
|
||||
import com.chwl.library.common.util.ClickUtils.click
|
||||
import com.chwl.library.net.rxnet.callback.CallBack
|
||||
import com.chwl.library.utils.SingleToastUtil
|
||||
import com.example.lib_utils.ktx.getString
|
||||
import io.reactivex.functions.Consumer
|
||||
|
||||
|
||||
class MicSelectDialog : BaseDialogFragment<DialogMicSelectBinding>() {
|
||||
|
||||
|
||||
override var width = WindowManager.LayoutParams.MATCH_PARENT
|
||||
override var height = WindowManager.LayoutParams.WRAP_CONTENT
|
||||
override var dimAmount = 0f
|
||||
override var gravity = Gravity.BOTTOM
|
||||
|
||||
|
||||
private lateinit var mAdapter: UpMicAdapter
|
||||
private val myUid = AuthModel.get().currentUid
|
||||
private var isMySelf = false
|
||||
|
||||
var targetUser = UserInfo()
|
||||
var homePartyModel: HomePartyModel? = null
|
||||
|
||||
var mPosition : Int? = null
|
||||
|
||||
override fun init() {
|
||||
|
||||
if (AvRoomDataManager.get().getChatRoomMember(targetUser.uid.toString()) == null) {
|
||||
SingleToastUtil.showToast(R.string.tips_member_not_in_room.getString())
|
||||
dismiss()
|
||||
}
|
||||
isMySelf = targetUser.uid == myUid
|
||||
|
||||
mAdapter = UpMicAdapter(context, targetUser.uid,
|
||||
Consumer<Int> { position: Int ->
|
||||
mPosition = position
|
||||
mPosition?.let {
|
||||
if (AvRoomDataManager.get().isLeaveMode && targetUser.uid == AvRoomDataManager.get().roomUid) {
|
||||
SingleToastUtil.showToast(R.string.tips_close_leave_mode_first.getString())
|
||||
dismiss()
|
||||
return@Consumer
|
||||
}
|
||||
|
||||
if (isMySelf) {
|
||||
val roomInfo = AvRoomDataManager.get().mCurrentRoomInfo ?: return@Consumer
|
||||
//自己抱自己上麦
|
||||
AvRoomDataManager.get().haveStartDragon = false
|
||||
homePartyModel?.upMicroPhone(
|
||||
it - 1,
|
||||
targetUser.uid.toString(),
|
||||
roomInfo.roomId.toString(),
|
||||
true,
|
||||
object : CallBack<String?> {
|
||||
override fun onSuccess(data: String?) {
|
||||
GiftValueMrg.get().requestUpMic(it - 1, targetUser.uid.toString())
|
||||
mActionCallBack?.onAction(0,null) //随便通知下外头
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, error: String?) {
|
||||
}
|
||||
}
|
||||
)
|
||||
dismiss()
|
||||
return@Consumer
|
||||
}
|
||||
|
||||
if (targetUser.defUser == UserInfo.USER_TYPE_ROBOT) {
|
||||
SingleToastUtil.showToast(R.string.unable_to_up_mic_by_level.getString())
|
||||
return@Consumer
|
||||
}
|
||||
|
||||
val baseInfo = BaseInfo(targetUser.uid, targetUser.nick)
|
||||
IMNetEaseManager.get().inviteMicroPhoneBySdk(baseInfo, it - 1).subscribe()
|
||||
dismiss()
|
||||
}
|
||||
})
|
||||
|
||||
binding.rvList.layoutManager = GridLayoutManager(context, 4, RecyclerView.VERTICAL, false)
|
||||
binding.rvList.adapter = mAdapter
|
||||
|
||||
|
||||
binding.confirm.click {
|
||||
|
||||
dismiss()
|
||||
}
|
||||
}
|
||||
|
||||
override fun onDestroy() {
|
||||
homePartyModel = null
|
||||
super.onDestroy()
|
||||
}
|
||||
|
||||
}
|
@@ -11,30 +11,28 @@ import android.content.ClipboardManager;
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.text.TextUtils;
|
||||
import android.view.Gravity;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.WindowManager;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.app.AppCompatDialog;
|
||||
import androidx.appcompat.widget.AppCompatImageView;
|
||||
import androidx.recyclerview.widget.GridLayoutManager;
|
||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.chwl.app.R;
|
||||
import com.chwl.app.UIHelper;
|
||||
import com.chwl.app.avroom.ButtonItemFactory;
|
||||
import com.chwl.app.avroom.activity.AVRoomActivity;
|
||||
import com.chwl.app.avroom.adapter.UpMicAdapter;
|
||||
import com.chwl.app.avroom.giftvalue.GiftValueDialogUiHelper;
|
||||
import com.chwl.app.avroom.widget.ViewItem;
|
||||
import com.chwl.app.base.BaseDialogFragment;
|
||||
import com.chwl.app.common.widget.dialog.DialogManager;
|
||||
import com.chwl.app.databinding.DialogUserInfoBinding;
|
||||
import com.chwl.app.room_chat.activity.RoomMsgActivity;
|
||||
import com.chwl.app.ui.im.avtivity.NimP2PMessageActivity;
|
||||
import com.chwl.app.ui.user.activity.UserInfoActivity;
|
||||
import com.chwl.app.ui.user.adapter.SkillPicsAdapter;
|
||||
import com.chwl.app.ui.user.decorationsend.UserInfoSkillDecoration;
|
||||
@@ -43,7 +41,6 @@ import com.chwl.app.ui.utils.ImageLoadUtils;
|
||||
import com.chwl.app.ui.utils.VipUtil;
|
||||
import com.chwl.app.utils.AvatarHelper;
|
||||
import com.chwl.app.utils.RegexUtil;
|
||||
import com.chwl.app.view.GenderAgeTextView;
|
||||
import com.chwl.app.vip.util.VipHelper;
|
||||
import com.chwl.core.Constants;
|
||||
import com.chwl.core.XConstants;
|
||||
@@ -76,7 +73,6 @@ import com.chwl.core.room.model.HomePartyModel;
|
||||
import com.chwl.core.super_admin.model.SuperAdminModel;
|
||||
import com.chwl.core.super_admin.util.SuperAdminUtil;
|
||||
import com.chwl.core.user.UserModel;
|
||||
import com.chwl.core.user.bean.BaseInfo;
|
||||
import com.chwl.core.user.bean.UserInfo;
|
||||
import com.chwl.core.utils.CoreLogger;
|
||||
import com.chwl.core.utils.StringFormatUtils;
|
||||
@@ -84,21 +80,16 @@ import com.chwl.core.utils.net.BeanObserver;
|
||||
import com.chwl.core.utils.net.DontWarnObserver;
|
||||
import com.chwl.core.utils.net.RxHelper;
|
||||
import com.chwl.core.vip.bean.UserVipInfo;
|
||||
import com.chwl.library.net.rxnet.callback.CallBack;
|
||||
import com.chwl.library.common.util.OtherExtKt;
|
||||
import com.chwl.library.utils.ListUtils;
|
||||
import com.chwl.library.utils.ResUtil;
|
||||
import com.chwl.library.utils.SingleToastUtil;
|
||||
import com.chwl.library.utils.config.BasicConfig;
|
||||
import com.chwl.library.widget.SVGAView;
|
||||
import com.coorchice.library.SuperTextView;
|
||||
import com.google.android.flexbox.FlexboxLayout;
|
||||
import com.hjq.toast.ToastUtils;
|
||||
import com.netease.nim.uikit.common.util.sys.ScreenUtil;
|
||||
import com.netease.nimlib.sdk.chatroom.ChatRoomMessageBuilder;
|
||||
import com.netease.nimlib.sdk.chatroom.model.ChatRoomKickOutEvent;
|
||||
import com.netease.nimlib.sdk.chatroom.model.ChatRoomMessage;
|
||||
import com.tencent.qgame.animplayer.AnimConfig;
|
||||
import com.tencent.qgame.animplayer.AnimView;
|
||||
import com.tencent.qgame.animplayer.inter.IAnimListener;
|
||||
import com.tencent.qgame.animplayer.util.ScaleType;
|
||||
|
||||
@@ -128,38 +119,8 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
private long uid;
|
||||
private boolean isAttention;
|
||||
private UserInfo userInfo;
|
||||
private ImageView closeImage;
|
||||
private FrameLayout avatarLayout;
|
||||
private SVGAView ivAvatarHeadWear;
|
||||
private ImageView avatar;
|
||||
/**
|
||||
* 头像高斯模糊背景
|
||||
*/
|
||||
private FrameLayout mUserCardWearLayout;
|
||||
private ImageView ivUserCardWear;
|
||||
private AnimView ivUserCardWearMP4;
|
||||
private ImageView ivAvatarBg;
|
||||
private SuperTextView ivAvatarBgMask;
|
||||
private ImageView ivBadge;
|
||||
private ImageView ivVipIcon;
|
||||
private TextView nick;
|
||||
private GenderAgeTextView mTvGenderAge;
|
||||
private TextView erbanId;
|
||||
private ImageView ivCopy;
|
||||
|
||||
private TextView fansNumber;
|
||||
private AppCompatImageView ivOfficialView;
|
||||
private AppCompatImageView ivNewUser;
|
||||
private AppCompatImageView mIvGoodNumber;
|
||||
private AppCompatImageView mIvUserLevel;
|
||||
private AppCompatImageView mIvUserCharm;
|
||||
private TextView tvFamilyNameLabel;
|
||||
private TextView tvFamilyName;
|
||||
private FlexboxLayout flexbox;
|
||||
|
||||
private View inOfficialMask;
|
||||
private View inNamePlate;
|
||||
private View inNamePlateVip;
|
||||
private DialogUserInfoBinding mBinding;
|
||||
|
||||
private long myUid;
|
||||
private Disposable subscribe;
|
||||
@@ -174,15 +135,12 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
private GiftDialog.OnGiftDialogBtnClickListener giftDialogBtnClickListener;
|
||||
|
||||
private SuperAdminModel mSuperAdminModel;
|
||||
|
||||
//找到他处理
|
||||
private ViewItem findHimView;
|
||||
|
||||
private TextView tvSelectHim;
|
||||
private View attentView;
|
||||
private String avatarBg;
|
||||
private SkillPicsAdapter picsAdapter;
|
||||
|
||||
private RecyclerView recyclerViewSkill;
|
||||
|
||||
private UserInfoDialog(Context context, UserInfo userInfo, long uid, List<ViewItem> buttons, boolean isInRoom, GiftDialog.OnGiftDialogBtnClickListener listener) {
|
||||
super(context, R.style.ErbanUserInfoDialog);
|
||||
@@ -210,7 +168,7 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
GiftDialog.OnGiftDialogBtnClickListener listener) {
|
||||
LoadingDialog loadingDialog = new LoadingDialog(context);
|
||||
loadingDialog.show();
|
||||
UserModel.get().getUserInfoFromServerUpdate(uid,false)
|
||||
UserModel.get().getUserInfoFromServerUpdate(uid, false)
|
||||
.compose(RxHelper.bindContext(context))
|
||||
.subscribe(userInfo -> {
|
||||
List<ViewItem> list = ButtonItemFactory.createCommonButtonItems(
|
||||
@@ -237,106 +195,92 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
super.onCreate(savedInstanceState);
|
||||
EventBus.getDefault().register(this);
|
||||
mCompositeDisposable = new CompositeDisposable();
|
||||
setContentView(R.layout.dialog_user_info);
|
||||
mBinding = DialogUserInfoBinding.inflate(LayoutInflater.from(context));
|
||||
setContentView(mBinding.getRoot());
|
||||
setCanceledOnTouchOutside(true);
|
||||
//设置全屏
|
||||
WindowManager.LayoutParams params = getWindow().getAttributes();
|
||||
params.width = WindowManager.LayoutParams.MATCH_PARENT;
|
||||
params.width = OtherExtKt.toDP(330);
|
||||
params.height = WindowManager.LayoutParams.WRAP_CONTENT;
|
||||
|
||||
setMicViewVisiable(false);
|
||||
closeImage = findViewById(R.id.close_image);
|
||||
avatarLayout = findViewById(R.id.fl_avatar_layout);
|
||||
avatar = findViewById(R.id.avatar);
|
||||
ivAvatarBg = findViewById(R.id.iv_avatar_bg);
|
||||
ivAvatarBgMask = findViewById(R.id.transition_mask);
|
||||
nick = findViewById(R.id.nick);
|
||||
erbanId = findViewById(R.id.tv_erban_id);
|
||||
ivCopy = findViewById(R.id.iv_copy);
|
||||
mTvGenderAge = findViewById(R.id.tv_gender_age);
|
||||
ivVipIcon = findViewById(R.id.iv_vip_icon);
|
||||
fansNumber = findViewById(R.id.fans_number);
|
||||
flexbox = findViewById(R.id.flexbox);
|
||||
myUid = AuthModel.get().getCurrentUid();
|
||||
|
||||
inOfficialMask = findViewById(R.id.in_official_mask);
|
||||
inNamePlate = findViewById(R.id.in_nameplate);
|
||||
inNamePlateVip = findViewById(R.id.inNameplateVip);
|
||||
mBinding.ivUserCardWearMp4.setScaleType(ScaleType.CENTER_CROP);
|
||||
mBinding.ivUserCardWearMp4.setLoop(Integer.MAX_VALUE);
|
||||
mBinding.ivUserCardWearMp4.setAnimListener(new IAnimListener() {
|
||||
@Override
|
||||
public boolean onVideoConfigReady(@NonNull AnimConfig animConfig) {
|
||||
return true;
|
||||
}
|
||||
|
||||
ivAvatarHeadWear = findViewById(R.id.iv_avatar_head_wear);
|
||||
ivAvatarHeadWear.bindCache(AVRoomActivity.getSvgaCache());
|
||||
ivBadge = findViewById(R.id.iv_badge);
|
||||
ivBadge.setVisibility(View.GONE);
|
||||
ivOfficialView = findViewById(R.id.iv_user_official);
|
||||
ivNewUser = (AppCompatImageView) findViewById(R.id.iv_new_user);
|
||||
mIvGoodNumber = findViewById(R.id.iv_good_number);
|
||||
mIvUserLevel = findViewById(R.id.iv_user_level);
|
||||
mIvUserCharm = findViewById(R.id.iv_user_charm);
|
||||
@Override
|
||||
public void onVideoStart() {
|
||||
}
|
||||
|
||||
mUserCardWearLayout = findViewById(R.id.userCardWearLayout);
|
||||
@Override
|
||||
public void onVideoRender(int i, @Nullable AnimConfig animConfig) {
|
||||
}
|
||||
|
||||
ivUserCardWear = findViewById(R.id.iv_user_card_wear);
|
||||
ivUserCardWearMP4 = findViewById(R.id.iv_user_card_wear_mp4);
|
||||
ivUserCardWearMP4.setScaleType(ScaleType.CENTER_CROP);
|
||||
ivUserCardWearMP4.setLoop(Integer.MAX_VALUE);
|
||||
ivUserCardWearMP4.setAnimListener(new IAnimListener() {
|
||||
@Override
|
||||
public boolean onVideoConfigReady(@NonNull AnimConfig animConfig) {return true;}
|
||||
public void onVideoComplete() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onVideoStart() {}
|
||||
@Override
|
||||
public void onVideoRender(int i, @Nullable AnimConfig animConfig) {}
|
||||
@Override
|
||||
public void onVideoComplete() {}
|
||||
@Override
|
||||
public void onVideoDestroy() {}
|
||||
public void onVideoDestroy() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFailed(int i, @Nullable String s) {
|
||||
ivUserCardWear.post(() -> {
|
||||
ImageLoadUtils.loadImage(context, userInfo.getUserInfoCardPic(), ivUserCardWear);
|
||||
mBinding.ivUserCardWear.post(() -> {
|
||||
ImageLoadUtils.loadImage(context, userInfo.getUserInfoCardPic(), mBinding.ivUserCardWear);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
tvFamilyNameLabel = (TextView) findViewById(R.id.tv_family_name_label);
|
||||
tvFamilyName = (TextView) findViewById(R.id.tv_family_name);
|
||||
tvSelectHim = findViewById(R.id.tv_select_him);
|
||||
avatarLayout.setOnClickListener(this);
|
||||
closeImage.setOnClickListener(this);
|
||||
|
||||
recyclerViewSkill = findViewById(R.id.recyclerview_skill_card);
|
||||
picsAdapter = new SkillPicsAdapter();
|
||||
recyclerViewSkill.setAdapter(picsAdapter);
|
||||
recyclerViewSkill.setLayoutManager(new LinearLayoutManager(context, LinearLayoutManager.HORIZONTAL, false));
|
||||
recyclerViewSkill.addItemDecoration(new UserInfoSkillDecoration(context, 8));
|
||||
TextView tvReport = findViewById(R.id.tv_report);
|
||||
if (tvReport != null) {
|
||||
if (isMySelf) {
|
||||
tvReport.setVisibility(View.GONE);
|
||||
} else {
|
||||
tvReport.setVisibility(View.VISIBLE);
|
||||
tvReport.setOnClickListener(this);
|
||||
}
|
||||
}
|
||||
mBinding.recyclerviewSkillCard.setAdapter(picsAdapter);
|
||||
mBinding.recyclerviewSkillCard.setLayoutManager(new LinearLayoutManager(context, LinearLayoutManager.HORIZONTAL, false));
|
||||
mBinding.recyclerviewSkillCard.addItemDecoration(new UserInfoSkillDecoration(context, 8));
|
||||
|
||||
myUid = AuthModel.get().getCurrentUid();
|
||||
|
||||
loadButtons();
|
||||
subscribe = IMNetEaseManager.get().getChatRoomEventObservable().subscribe(this::onReceiveRoomEvent);
|
||||
initAttentData();
|
||||
initDatingData();
|
||||
updateView();
|
||||
|
||||
|
||||
if (isMySelf) {
|
||||
mBinding.tvReport.setVisibility(View.GONE);
|
||||
} else {
|
||||
mBinding.tvReport.setVisibility(View.VISIBLE);
|
||||
mBinding.tvReport.setOnClickListener(this);
|
||||
}
|
||||
|
||||
mBinding.flAvatarLayout.setOnClickListener(this);
|
||||
mBinding.gift.setOnClickListener(this);
|
||||
mBinding.send.setOnClickListener(this);
|
||||
mBinding.aite.setOnClickListener(this);
|
||||
mBinding.follow.setOnClickListener(this);
|
||||
|
||||
mBinding.gift.setVisibility(View.VISIBLE);
|
||||
if (!isMySelf){
|
||||
mBinding.send.setVisibility(View.VISIBLE);
|
||||
mBinding.aite.setVisibility(View.VISIBLE);
|
||||
mBinding.follow.setVisibility(View.VISIBLE);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void initAttentData() {
|
||||
if (isMySelf) {
|
||||
tvFamilyNameLabel.setText(tvFamilyNameLabel.getText().toString().replace("TA", getString(R.string.ui_widget_userinfodialog_01)));
|
||||
mBinding.tvFamilyNameLabel.setText(mBinding.tvFamilyNameLabel.getText().toString().replace("TA", getString(R.string.ui_widget_userinfodialog_01)));
|
||||
} else {
|
||||
Disposable disposable = PraiseModel.get().isPraised(myUid, uid).subscribe(aBoolean -> {
|
||||
isAttention = aBoolean;
|
||||
if (attentView == null) return;
|
||||
updateAttentView();
|
||||
attentView.setOnClickListener(new View.OnClickListener() {
|
||||
mBinding.follow.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
toAttent();
|
||||
@@ -358,8 +302,8 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
myUid != uid &&
|
||||
!AvRoomDataManager.get().isPreside(myUid) &&
|
||||
!AvRoomDataManager.get().isPreside(uid)) {
|
||||
tvSelectHim.setVisibility(View.VISIBLE);
|
||||
tvSelectHim.setOnClickListener(v -> {
|
||||
mBinding.tvSelectHim.setVisibility(View.VISIBLE);
|
||||
mBinding.tvSelectHim.setOnClickListener(v -> {
|
||||
int micPosition = AvRoomDataManager.get().getMicPosition(uid);
|
||||
if (micPosition == Integer.MIN_VALUE) {
|
||||
SingleToastUtil.showToast(getString(R.string.ui_widget_userinfodialog_02));
|
||||
@@ -369,10 +313,12 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
}
|
||||
);
|
||||
} else {
|
||||
tvSelectHim.setVisibility(View.GONE);
|
||||
mBinding.tvSelectHim.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||
public void onDatingSelectUserEvent(DatingSelectUserEvent event) {
|
||||
try {
|
||||
@@ -382,21 +328,8 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param isVisiable ture则表示上麦的网格布局可见
|
||||
*/
|
||||
@SuppressWarnings("ConstantConditions")
|
||||
private void setMicViewVisiable(boolean isVisiable) {
|
||||
findViewById(R.id.recycler_view_mic).setVisibility(isVisiable ? View.VISIBLE : View.GONE);
|
||||
findViewById(R.id.layout_grid_button).setVisibility(isVisiable ? View.GONE : View.VISIBLE);
|
||||
}
|
||||
|
||||
private void updateAttentView() {
|
||||
TextView textView = attentView.findViewById(R.id.text);
|
||||
textView.setText(isAttention ? getString(R.string.ui_widget_userinfodialog_03) : getString(R.string.ui_widget_userinfodialog_04));
|
||||
ImageView imageView = attentView.findViewById(R.id.image);
|
||||
imageView.setImageResource(
|
||||
isAttention ? R.drawable.icon_dialog_cancel_attent : R.drawable.icon_dialog_attent);
|
||||
mBinding.follow.setImageResource(isAttention ? R.drawable.icon_dialog_cancel_attent : R.drawable.icon_dialog_attent);
|
||||
}
|
||||
|
||||
private void loadButtons() {
|
||||
@@ -412,67 +345,52 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
|
||||
private void addViewItems(List<ViewItem> buttons) {
|
||||
if (ListUtils.isListEmpty(buttons)) {
|
||||
findViewById(R.id.layout_grid_button).setVisibility(View.GONE);
|
||||
mBinding.flexbox.setVisibility(View.GONE);
|
||||
return;
|
||||
}
|
||||
int dialogWidth = flexbox.getMeasuredWidth() == 0 ? ScreenUtil.dip2px(285) : flexbox.getMeasuredWidth();
|
||||
int itemWidth = dialogWidth / 4;
|
||||
if (buttons.size() < 4) itemWidth = dialogWidth / 3;
|
||||
flexbox.removeAllViews();
|
||||
//底部item,不添加到网格
|
||||
List<ViewItem> bottomList = new ArrayList<>();
|
||||
for (int i = 0; i < buttons.size(); i++) {
|
||||
ViewItem buttonItem = buttons.get(i);
|
||||
if (buttonItem.mButtonType == ViewItem.BUTTON_TYPE_NORMAL) {
|
||||
View item = LayoutInflater.from(getContext()).inflate(buttonItem.resourceID, flexbox, false);
|
||||
item.getLayoutParams().width = itemWidth;
|
||||
TextView textView = item.findViewById(R.id.text);
|
||||
textView.setText(buttonItem.mText);
|
||||
textView.setGravity(Gravity.CENTER);
|
||||
ImageView imageView = item.findViewById(R.id.image);
|
||||
imageView.setImageResource(buttonItem.imgRes);
|
||||
//关注按钮的处理
|
||||
if (buttonItem.isAttent) {
|
||||
if (!isMySelf) {
|
||||
flexbox.addView(item);
|
||||
attentView = item;
|
||||
}
|
||||
} else if (buttonItem.isFindTa) {
|
||||
//找到他处理
|
||||
if (!isMySelf) {
|
||||
findHimView = buttonItem;
|
||||
}
|
||||
} else if (buttonItem.isAt) {
|
||||
//@他处理
|
||||
if (!isMySelf) {
|
||||
item.setOnClickListener(v -> {
|
||||
if (userInfo != null) {
|
||||
dismiss();
|
||||
EventBus.getDefault().post(
|
||||
new RoomAtEvent(String.valueOf(userInfo.getUid()), userInfo.getNick())
|
||||
);
|
||||
} else {
|
||||
SingleToastUtil.showToast(getString(R.string.ui_widget_userinfodialog_05));
|
||||
mBinding.flexbox.post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
// int dialogWidth = flexbox.getMeasuredWidth() == 0 ? ScreenUtil.dip2px(285) : flexbox.getMeasuredWidth();
|
||||
int dialogWidth = mBinding.flexbox.getWidth();
|
||||
int itemWidth = dialogWidth / 4;
|
||||
if (buttons.size() < 4) itemWidth = dialogWidth / 3;
|
||||
mBinding.flexbox.removeAllViews();
|
||||
//底部item,不添加到网格
|
||||
List<ViewItem> bottomList = new ArrayList<>();
|
||||
for (int i = 0; i < buttons.size(); i++) {
|
||||
ViewItem buttonItem = buttons.get(i);
|
||||
if (buttonItem.mButtonType == ViewItem.BUTTON_TYPE_NORMAL) {
|
||||
View item = LayoutInflater.from(getContext()).inflate(R.layout.dialog_user_card_item_new, mBinding.flexbox, false);
|
||||
item.getLayoutParams().width = itemWidth;
|
||||
ImageView imageView = item.findViewById(R.id.image);
|
||||
imageView.setImageResource(buttonItem.imgRes);
|
||||
if (buttonItem.isFindTa) {
|
||||
//找到他处理
|
||||
if (!isMySelf) {
|
||||
findHimView = buttonItem;
|
||||
}
|
||||
});
|
||||
flexbox.addView(item);
|
||||
}
|
||||
} else {
|
||||
item.setOnClickListener(v -> {
|
||||
buttonItem.mClickListener.onClick();
|
||||
if (!buttonItem.noDissmis) {
|
||||
dismiss();
|
||||
} else {
|
||||
item.setOnClickListener(v -> {
|
||||
buttonItem.mClickListener.onClick();
|
||||
if (!buttonItem.noDissmis) {
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
mBinding.flexbox.addView(item);
|
||||
}
|
||||
});
|
||||
flexbox.addView(item);
|
||||
} else if (buttonItem.mButtonType == ViewItem.BUTTON_TYPE_USER_CAR_BOTTOM) {
|
||||
bottomList.add(buttonItem);
|
||||
}
|
||||
}
|
||||
if (mBinding.flexbox.getChildCount() == 0) {
|
||||
mBinding.flexbox.setVisibility(View.GONE);
|
||||
} else {
|
||||
mBinding.flexbox.setVisibility(View.VISIBLE);
|
||||
}
|
||||
} else if (buttonItem.mButtonType == ViewItem.BUTTON_TYPE_USER_CAR_BOTTOM) {
|
||||
bottomList.add(buttonItem);
|
||||
}
|
||||
}
|
||||
if (flexbox.getChildCount() == 0) {
|
||||
findViewById(R.id.layout_grid_button).setVisibility(View.GONE);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -523,46 +441,44 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
|
||||
private void updateView() {
|
||||
if (userInfo != null) {
|
||||
ivOfficialView.setVisibility(userInfo.isOfficial() ? View.VISIBLE : View.GONE);
|
||||
ivNewUser.setVisibility(userInfo.isNewUser() ? View.VISIBLE : View.GONE);
|
||||
ivNewUser.setImageResource(userInfo.isFromSayHelloChannel() ? R.drawable.ic_new_user_hello : R.drawable.ic_new_user);
|
||||
mIvGoodNumber.setVisibility(userInfo.isHasPrettyErbanNo() ? View.VISIBLE : View.GONE);
|
||||
mBinding.ivUserOfficial.setVisibility(userInfo.isOfficial() ? View.VISIBLE : View.GONE);
|
||||
mBinding.ivNewUser.setVisibility(userInfo.isNewUser() ? View.VISIBLE : View.GONE);
|
||||
mBinding.ivNewUser.setImageResource(userInfo.isFromSayHelloChannel() ? R.drawable.ic_new_user_hello : R.drawable.ic_new_user);
|
||||
mBinding.ivGoodNumber.setVisibility(userInfo.isHasPrettyErbanNo() ? View.VISIBLE : View.GONE);
|
||||
|
||||
// 这个方法能让图片不失真
|
||||
ImageLoadUtils.loadAvatar(context, userInfo.getAvatar(), avatar);
|
||||
nick.setText(RegexUtil.getPrintableString(userInfo.getNick()));
|
||||
erbanId.setText(getString(R.string.ui_widget_userinfodialog_06) + userInfo.getErbanNo());
|
||||
erbanId.setOnLongClickListener(view -> {
|
||||
ImageLoadUtils.loadAvatar(context, userInfo.getAvatar(), mBinding.avatar);
|
||||
mBinding.nick.setText(RegexUtil.getPrintableString(userInfo.getNick()));
|
||||
mBinding.tvErbanId.setText(getString(R.string.ui_widget_userinfodialog_06) + userInfo.getErbanNo());
|
||||
mBinding.tvErbanId.setOnLongClickListener(view -> {
|
||||
copyName();
|
||||
return true;
|
||||
});
|
||||
ivCopy.setOnClickListener(view -> copyName());
|
||||
mTvGenderAge.setBirthDay(userInfo.getBirth());
|
||||
mTvGenderAge.setGender(userInfo.getGender());
|
||||
VipHelper.loadVipIcon(ivVipIcon, userInfo.getUserVipInfoVO());
|
||||
// 设置粉丝数量
|
||||
fansNumber.setText(userInfo.getFansNum() + getString(R.string.ui_widget_userinfodialog_07));
|
||||
mBinding.ivCopy.setOnClickListener(view -> copyName());
|
||||
mBinding.tvGenderAge.setBirthDay(userInfo.getBirth());
|
||||
mBinding.tvGenderAge.setGender(userInfo.getGender());
|
||||
VipHelper.loadVipIcon(mBinding.ivVipIcon, userInfo.getUserVipInfoVO());
|
||||
|
||||
//设置家族
|
||||
if (FamilyInfo.NO_FAMILY_ID.equals(userInfo.getFamilyId())
|
||||
|| TextUtils.isEmpty(userInfo.getFamilyId())
|
||||
|| MarketVerifyModel.get().isMarketChecking()) {
|
||||
tvFamilyName.setText(context.getResources().getString(R.string.empty_family_text));
|
||||
mBinding.tvFamilyName.setText(context.getResources().getString(R.string.empty_family_text));
|
||||
} else {
|
||||
loadSimpleFamilyInfo(userInfo.getFamilyId());
|
||||
}
|
||||
|
||||
UserLevelVo userLevelVo = userInfo.getUserLevelVo();
|
||||
mIvUserLevel.setVisibility(userLevelVo == null ? View.GONE : View.VISIBLE);
|
||||
mIvUserCharm.setVisibility(View.GONE);
|
||||
mBinding.ivUserLevel.setVisibility(userLevelVo == null ? View.GONE : View.VISIBLE);
|
||||
mBinding.ivUserCharm.setVisibility(View.GONE);
|
||||
if (userLevelVo != null) {
|
||||
mIvUserLevel.setVisibility(TextUtils.isEmpty(userLevelVo.getExperUrl()) ? View.GONE : View.VISIBLE);
|
||||
mBinding.ivUserLevel.setVisibility(TextUtils.isEmpty(userLevelVo.getExperUrl()) ? View.GONE : View.VISIBLE);
|
||||
if (!TextUtils.isEmpty(userLevelVo.getExperUrl())) {
|
||||
ImageLoadUtils.loadImage(context, userLevelVo.getExperUrl(), mIvUserLevel);
|
||||
ImageLoadUtils.loadImage(context, userLevelVo.getExperUrl(), mBinding.ivUserLevel);
|
||||
}
|
||||
if (!TextUtils.isEmpty(userLevelVo.getCharmUrl())) {
|
||||
mIvUserCharm.setVisibility(View.VISIBLE);
|
||||
ImageLoadUtils.loadImage(context, userLevelVo.getCharmUrl(), mIvUserCharm);
|
||||
mBinding.ivUserCharm.setVisibility(View.VISIBLE);
|
||||
ImageLoadUtils.loadImage(context, userLevelVo.getCharmUrl(), mBinding.ivUserCharm);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -608,7 +524,7 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
int dialogWidth = context.getResources().getDimensionPixelOffset(
|
||||
R.dimen.dp_room_user_dialog_width);
|
||||
int itemWidth = dialogWidth / 4;
|
||||
View item = LayoutInflater.from(getContext()).inflate(findHimView.resourceID, flexbox, false);
|
||||
View item = LayoutInflater.from(getContext()).inflate(findHimView.resourceID, mBinding.flexbox, false);
|
||||
item.getLayoutParams().width = itemWidth;
|
||||
TextView textView = item.findViewById(R.id.text);
|
||||
textView.setText(findHimView.mText);
|
||||
@@ -620,7 +536,7 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
AVRoomActivity.start(context, roomResult.getData().getUid());
|
||||
}
|
||||
});
|
||||
flexbox.addView(item);
|
||||
mBinding.flexbox.addView(item);
|
||||
|
||||
}
|
||||
|
||||
@@ -634,9 +550,9 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
});
|
||||
}
|
||||
if (userInfo.getAbsCardPics() == null) {
|
||||
recyclerViewSkill.setVisibility(View.GONE);
|
||||
mBinding.recyclerviewSkillCard.setVisibility(View.GONE);
|
||||
} else {
|
||||
recyclerViewSkill.setVisibility(View.VISIBLE);
|
||||
mBinding.recyclerviewSkillCard.setVisibility(View.VISIBLE);
|
||||
picsAdapter.setNewData(userInfo.getAbsCardPics());
|
||||
}
|
||||
}
|
||||
@@ -655,54 +571,30 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
|
||||
private void setNamePlate(String nameplatePic, String nameplateWord) {
|
||||
if (!TextUtils.isEmpty(nameplateWord) && !TextUtils.isEmpty(nameplatePic)) {
|
||||
inNamePlate.setVisibility(View.VISIBLE);
|
||||
TextView tvNamePlate;
|
||||
tvNamePlate = inNamePlate.findViewById(R.id.tv_official_mask);
|
||||
if (tvNamePlate != null) {
|
||||
tvNamePlate.setText(nameplateWord);
|
||||
}
|
||||
|
||||
ImageView ivNamePlate;
|
||||
ivNamePlate = inNamePlate.findViewById(R.id.iv_official_mask);
|
||||
if (ivNamePlate != null) {
|
||||
ImageLoadUtils.loadImage(context, nameplatePic, ivNamePlate);
|
||||
}
|
||||
|
||||
mBinding.inNameplate.getRoot().setVisibility(View.VISIBLE);
|
||||
mBinding.inNameplate.tvOfficialMask.setText(nameplateWord);
|
||||
ImageLoadUtils.loadImage(context, nameplatePic, mBinding.inNameplate.ivOfficialMask);
|
||||
} else {
|
||||
inNamePlate.setVisibility(View.GONE);
|
||||
mBinding.inNameplate.getRoot().setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
private void setNamePlateVip(String nameplatePic) {
|
||||
if (!TextUtils.isEmpty(nameplatePic)) {
|
||||
inNamePlateVip.setVisibility(View.VISIBLE);
|
||||
ImageView ivNamePlate;
|
||||
ivNamePlate = inNamePlateVip.findViewById(R.id.iv_official_mask);
|
||||
if (ivNamePlate != null) {
|
||||
ImageLoadUtils.loadImage(context, nameplatePic, ivNamePlate);
|
||||
}
|
||||
mBinding.inNameplateVip.getRoot().setVisibility(View.VISIBLE);
|
||||
ImageLoadUtils.loadImage(context, nameplatePic, mBinding.inNameplateVip.ivOfficialMask);
|
||||
} else {
|
||||
inNamePlateVip.setVisibility(View.GONE);
|
||||
mBinding.inNameplateVip.getRoot().setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
private void setOfficialMask(String name, String icon) {
|
||||
if (!TextUtils.isEmpty(name) && !TextUtils.isEmpty(icon)) {
|
||||
inOfficialMask.setVisibility(View.VISIBLE);
|
||||
TextView tvOfficialMask;
|
||||
tvOfficialMask = inOfficialMask.findViewById(R.id.tv_official_mask);
|
||||
if (tvOfficialMask != null) {
|
||||
tvOfficialMask.setText(name);
|
||||
}
|
||||
|
||||
ImageView ivOfficialMask;
|
||||
ivOfficialMask = inOfficialMask.findViewById(R.id.iv_official_mask);
|
||||
if (ivOfficialMask != null) {
|
||||
NobleUtil.loadResource(icon, ivOfficialMask);
|
||||
}
|
||||
|
||||
mBinding.inOfficialMask.setVisibility(View.VISIBLE);
|
||||
mBinding.tvOfficialMask.setText(name);
|
||||
NobleUtil.loadResource(icon, mBinding.ivOfficialMask);
|
||||
} else {
|
||||
inOfficialMask.setVisibility(View.GONE);
|
||||
mBinding.inOfficialMask.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -718,7 +610,7 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
|
||||
@Override
|
||||
public void onSuccess(FamilyInfo familyInfo) {
|
||||
tvFamilyName.setText(familyInfo.getFamilyName());
|
||||
mBinding.tvFamilyName.setText(familyInfo.getFamilyName());
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -740,95 +632,72 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
String avatarFrame = userHeadwear.getFirstUrl();
|
||||
if (!TextUtils.isEmpty(avatarFrame)) {
|
||||
havaHead = true;
|
||||
AvatarHelper.loadAvatarFrame(ivAvatarHeadWear, avatarFrame, userHeadwear.getType());
|
||||
AvatarHelper.loadAvatarFrame(mBinding.ivAvatarHeadWear, avatarFrame, userHeadwear.getType());
|
||||
}
|
||||
}
|
||||
|
||||
//资料卡装扮
|
||||
ivAvatarBgMask.setVisibility(View.INVISIBLE);
|
||||
ivAvatarBg.setVisibility(View.INVISIBLE);
|
||||
mBinding.transitionMask.setVisibility(View.INVISIBLE);
|
||||
mBinding.ivAvatarBg.setVisibility(View.INVISIBLE);
|
||||
|
||||
if (userInfo.getInfoCardVo() != null) {
|
||||
VipUtil.INSTANCE.setUserBg(userInfo.getInfoCardVo(), mUserCardWearLayout, callBack -> {
|
||||
VipUtil.INSTANCE.setUserBg(userInfo.getInfoCardVo(), mBinding.userCardWearLayout, callBack -> {
|
||||
if (callBack) {
|
||||
ivAvatarBgMask.setVisibility(View.INVISIBLE);
|
||||
ivAvatarBg.setVisibility(View.INVISIBLE);
|
||||
mBinding.transitionMask.setVisibility(View.INVISIBLE);
|
||||
mBinding.ivAvatarBg.setVisibility(View.INVISIBLE);
|
||||
} else {
|
||||
if (avatarBg == null || !avatarBg.equals(userInfo.getAvatar())) {
|
||||
avatarBg = userInfo.getAvatar();
|
||||
ImageLoadUtils.loadImageWithBlur(context, userInfo.getAvatar(), ivAvatarBg, 10, 1);
|
||||
ivAvatarBgMask.setVisibility(View.VISIBLE);
|
||||
ivAvatarBg.setVisibility(View.VISIBLE);
|
||||
ImageLoadUtils.loadImageWithBlur(context, userInfo.getAvatar(), mBinding.ivAvatarBg, 10, 1);
|
||||
mBinding.transitionMask.setVisibility(View.VISIBLE);
|
||||
mBinding.ivAvatarBg.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
return null;
|
||||
});
|
||||
} else {
|
||||
|
||||
ivAvatarBg.setVisibility(View.VISIBLE);
|
||||
mBinding.ivAvatarBg.setVisibility(View.VISIBLE);
|
||||
if (vipInfo != null && !vipInfo.getUserCardBG().isEmpty()) {
|
||||
// findViewById(R.id.transition_mask).setVisibility(View.GONE);
|
||||
ivAvatarBg.setScaleType(ImageView.ScaleType.MATRIX);
|
||||
mBinding.ivAvatarBg.setScaleType(ImageView.ScaleType.FIT_XY);
|
||||
ImageLoadUtils.loadImage(
|
||||
context,
|
||||
vipInfo.getUserCardBG().replace("\n",""),
|
||||
ivAvatarBg,
|
||||
vipInfo.getUserCardBG().replace("\n", ""),
|
||||
mBinding.ivAvatarBg,
|
||||
R.drawable.default_avatar
|
||||
);
|
||||
} else {
|
||||
if (avatarBg == null || !avatarBg.equals(userInfo.getAvatar())) {
|
||||
avatarBg = userInfo.getAvatar();
|
||||
ImageLoadUtils.loadImageWithBlur(context, userInfo.getAvatar(), ivAvatarBg, 10, 1);
|
||||
mBinding.ivAvatarBg.setScaleType(ImageView.ScaleType.CENTER);
|
||||
ImageLoadUtils.loadImageWithBlur(context, userInfo.getAvatar(), mBinding.ivAvatarBg, 10, 1);
|
||||
}
|
||||
}
|
||||
|
||||
//资料卡装扮
|
||||
if (!TextUtils.isEmpty(userInfo.getUserInfoCardPic())) {
|
||||
ivUserCardWearMP4.post(() -> {
|
||||
ImageLoadKt.loadAnim2(ivUserCardWearMP4,userInfo.getUserInfoCardPic(),false,aBoolean -> {
|
||||
mBinding.ivUserCardWearMp4.post(() -> {
|
||||
ImageLoadKt.loadAnim2(mBinding.ivUserCardWearMp4, userInfo.getUserInfoCardPic(), false, aBoolean -> {
|
||||
if (!aBoolean) {
|
||||
ImageLoadUtils.loadImage(context, userInfo.getUserInfoCardPic(), ivUserCardWear);
|
||||
ImageLoadUtils.loadImage(context, userInfo.getUserInfoCardPic(), mBinding.ivUserCardWear);
|
||||
}
|
||||
return null;
|
||||
});
|
||||
});
|
||||
} else {
|
||||
ivUserCardWear.setImageDrawable(null);
|
||||
ivUserCardWearMP4.setVisibility(View.GONE);
|
||||
mBinding.ivUserCardWear.setImageDrawable(null);
|
||||
mBinding.ivUserCardWearMp4.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// if (nobleInfo == null || TextUtils.isEmpty(nobleInfo.getCardBg())) {
|
||||
// //如果没贵族信息,就加载头像作为背景
|
||||
// if (avatarBg == null || !avatarBg.equals(userInfo.getAvatar())) {
|
||||
// avatarBg = userInfo.getAvatar();
|
||||
// ImageLoadUtils.loadImageWithBlur(context, userInfo.getAvatar(), ivAvatarBg, 10, 1);
|
||||
// }
|
||||
// return;
|
||||
// }
|
||||
// // 卡片背景
|
||||
// if (!TextUtils.isEmpty(nobleInfo.getCardBg()) && !topBg.equals(nobleInfo.getCardBg())) {
|
||||
// topBg = nobleInfo.getCardBg();
|
||||
// NobleUtil.loadResource(nobleInfo.getCardBg(), ivAvatarBg, R.drawable.bg_user_info_dialog_top);
|
||||
// }
|
||||
// if (!TextUtils.isEmpty(nobleInfo.getHeadWear())) {
|
||||
// // 头饰
|
||||
// if (!havaHead) {
|
||||
// NobleUtil.loadResource(nobleInfo.getHeadWear(), ivAvatarHeadWear);
|
||||
// }
|
||||
// }
|
||||
// if (!TextUtils.isEmpty(nobleInfo.getBadge())) {
|
||||
// // 勋章
|
||||
// ivBadge.setVisibility(View.VISIBLE);
|
||||
// NobleUtil.loadResource(nobleInfo.getBadge(), ivBadge);
|
||||
// }
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void onDetachedFromWindow() {
|
||||
;
|
||||
super.onDetachedFromWindow();
|
||||
if (subscribe != null) {
|
||||
subscribe.dispose();
|
||||
@@ -844,19 +713,37 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
switch (v.getId()) {
|
||||
case R.id.close_image:
|
||||
dismiss();
|
||||
break;
|
||||
case R.id.tv_report:
|
||||
UIHelper.showReportPage(context, uid, XConstants.REPORT_TYPE_USERCARD);
|
||||
dismiss();
|
||||
break;
|
||||
case R.id.fl_avatar_layout:
|
||||
UserInfoActivity.Companion.start(context, uid);
|
||||
dismiss();
|
||||
break;
|
||||
default:
|
||||
if (v.getId() == mBinding.tvReport.getId()) {
|
||||
UIHelper.showReportPage(context, uid, XConstants.REPORT_TYPE_USERCARD);
|
||||
dismiss();
|
||||
} else if (v.getId() == mBinding.flAvatarLayout.getId()) {
|
||||
UserInfoActivity.Companion.start(context, uid);
|
||||
dismiss();
|
||||
} else if (v.getId() == mBinding.gift.getId()) {
|
||||
GiftDialog dialog = new GiftDialog(context, uid, isInRoom, false, true);
|
||||
if (giftDialogBtnClickListener != null) {
|
||||
dialog.setGiftDialogBtnClickListener(giftDialogBtnClickListener);
|
||||
}
|
||||
dialog.show();
|
||||
dismiss();
|
||||
} else if (v.getId() == mBinding.send.getId()) {
|
||||
if (isInRoom) {
|
||||
RoomMsgActivity.startForPrivateChat(context, String.valueOf(uid));
|
||||
} else {
|
||||
NimP2PMessageActivity.start(context, String.valueOf(uid));
|
||||
}
|
||||
} else if (v.getId() == mBinding.aite.getId()) {
|
||||
//@他处理
|
||||
if (!isMySelf) {
|
||||
if (userInfo != null) {
|
||||
dismiss();
|
||||
EventBus.getDefault().post(new RoomAtEvent(String.valueOf(userInfo.getUid()), userInfo.getNick()));
|
||||
} else {
|
||||
SingleToastUtil.showToast(getString(R.string.ui_widget_userinfodialog_05));
|
||||
}
|
||||
}
|
||||
} else if (v.getId() == mBinding.follow.getId()) {
|
||||
toAttent();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -938,8 +825,8 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
AvRoomDataManager.get().isDatingVipMic(micPosition);
|
||||
//超管逻辑
|
||||
if (SuperAdminUtil.isSuperAdmin()) {
|
||||
if(isMySelf) {
|
||||
buttonItems.add(createGiveGiftMicItem());//添加送礼物按钮
|
||||
if (isMySelf) {
|
||||
mBinding.gift.setVisibility(View.VISIBLE);
|
||||
}
|
||||
if (isTargetOnMic) {
|
||||
if (isMySelf) {
|
||||
@@ -971,7 +858,6 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
if (AvRoomDataManager.get().isRoomOwner()) {
|
||||
//房主操作
|
||||
if (isMySelf) {
|
||||
buttonItems.add(createGiveGiftMicItem());//添加送礼物按钮
|
||||
//开闭麦
|
||||
if (micPosition != AvRoomDataManager.POSITON_NOT_ON_MIC) {
|
||||
if (roomMicInfo != null) {
|
||||
@@ -1039,7 +925,6 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
} else if (AvRoomDataManager.get().isRoomAdmin()) {
|
||||
//管理员操作
|
||||
if (isMySelf) {
|
||||
buttonItems.add(createGiveGiftMicItem());//添加送礼物按钮
|
||||
//开闭麦
|
||||
if (micPosition != AvRoomDataManager.POSITON_NOT_ON_MIC) {
|
||||
if (roomMicInfo != null) {
|
||||
@@ -1116,10 +1001,7 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
} else {
|
||||
//游客操作
|
||||
if (isMySelf && isTargetOnMic) {
|
||||
buttonItems.add(createGiveGiftMicItem());
|
||||
buttonItems.add(createDownMicItem());
|
||||
} else if (isMySelf) {
|
||||
buttonItems.add(createGiveGiftMicItem());
|
||||
}
|
||||
return buttonItems;
|
||||
}
|
||||
@@ -1136,6 +1018,24 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
}
|
||||
}
|
||||
|
||||
private ViewItem createInviteMicItem() {
|
||||
return new ViewItem(getString(R.string.ui_widget_userinfodialog_028),
|
||||
R.drawable.user_card_ic_open_mic,
|
||||
true,
|
||||
() -> {
|
||||
//todo do 弹起 麦位选择布局
|
||||
MicSelectDialog dialog = new MicSelectDialog();
|
||||
dialog.setMActionCallBack(new BaseDialogFragment.Action() {
|
||||
@Override
|
||||
public <D> void onAction(int type, @Nullable D data) {
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
dialog.setTargetUser(userInfo);
|
||||
dialog.setHomePartyModel(homePartyModel);
|
||||
dialog.show(context);
|
||||
});
|
||||
}
|
||||
|
||||
private ViewItem createClearGiftValueItem() {
|
||||
return new ViewItem(getString(R.string.ui_widget_userinfodialog_013), R.drawable.user_card_ic_clean_gift_value, true, new ViewItem.OnClickListener() {
|
||||
@@ -1246,86 +1146,6 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
});
|
||||
}
|
||||
|
||||
private ViewItem createGiveGiftMicItem() {
|
||||
return new ViewItem(getString(R.string.give_gift), R.drawable.icon_send_gift_ture, true, new ViewItem.OnClickListener() {
|
||||
@Override
|
||||
public void onClick() {
|
||||
GiftDialog dialog = new GiftDialog(context, uid, isInRoom, false, true);
|
||||
if (giftDialogBtnClickListener != null) {
|
||||
dialog.setGiftDialogBtnClickListener(giftDialogBtnClickListener);
|
||||
}
|
||||
dialog.show();
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private ViewItem createInviteMicItem() {
|
||||
return new ViewItem(getString(R.string.ui_widget_userinfodialog_028), R.drawable.user_card_ic_open_mic, true, new ViewItem.OnClickListener() {
|
||||
@Override
|
||||
public void onClick() {
|
||||
if (AvRoomDataManager.get().getChatRoomMember(String.valueOf(uid)) == null) {
|
||||
SingleToastUtil.showToast(context.getString(R.string.tips_member_not_in_room));
|
||||
dismiss();
|
||||
return;
|
||||
}
|
||||
setMicViewVisiable(true);
|
||||
RecyclerView recyclerView = findViewById(R.id.recycler_view_mic);
|
||||
|
||||
UpMicAdapter adapter = new UpMicAdapter(context, uid,
|
||||
position -> {
|
||||
if (AvRoomDataManager.get().isLeaveMode() && uid == AvRoomDataManager.get().getRoomUid()) {
|
||||
SingleToastUtil.showToast(context.getString(R.string.tips_close_leave_mode_first));
|
||||
dismiss();
|
||||
return;
|
||||
}
|
||||
if (isMySelf) {
|
||||
RoomInfo roomInfo = AvRoomDataManager.get().mCurrentRoomInfo;
|
||||
if (roomInfo == null) {
|
||||
return;
|
||||
}
|
||||
//自己抱自己上麦
|
||||
AvRoomDataManager.get().haveStartDragon = false;
|
||||
homePartyModel.upMicroPhone(
|
||||
position - 1,
|
||||
String.valueOf(uid),
|
||||
String.valueOf(roomInfo.getRoomId()),
|
||||
true,
|
||||
new CallBack<String>() {
|
||||
@Override
|
||||
public void onSuccess(String data) {
|
||||
GiftValueMrg.get().requestUpMic(position - 1, String.valueOf(uid));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFail(int code, String error) {
|
||||
|
||||
}
|
||||
}
|
||||
);
|
||||
dismiss();
|
||||
return;
|
||||
}
|
||||
|
||||
String nick = null;
|
||||
if (userInfo != null) {
|
||||
nick = userInfo.getNick();
|
||||
|
||||
if (userInfo.getDefUser() == UserInfo.USER_TYPE_ROBOT) {
|
||||
SingleToastUtil.showToast(context.getString(R.string.unable_to_up_mic_by_level));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
BaseInfo baseInfo = new BaseInfo(uid, nick);
|
||||
IMNetEaseManager.get().inviteMicroPhoneBySdk(baseInfo, position - 1).subscribe();
|
||||
dismiss();
|
||||
});
|
||||
recyclerView.setLayoutManager(new GridLayoutManager(getContext(), 4));
|
||||
recyclerView.setAdapter(adapter);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@SuppressLint("CheckResult")
|
||||
private ViewItem createKickMicItem() {
|
||||
@@ -1334,7 +1154,7 @@ public class UserInfoDialog extends AppCompatDialog implements View.OnClickListe
|
||||
public void onClick() {
|
||||
|
||||
if (VipHelper.notKick(userInfo)) {
|
||||
ToastUtils.show(ResUtil.getString(R.string.vipPower,userInfo.getUserVipInfoVO().getVipLevel()));
|
||||
ToastUtils.show(ResUtil.getString(R.string.vipPower, userInfo.getUserVipInfoVO().getVipLevel()));
|
||||
return;
|
||||
}
|
||||
|
||||
|
40
app/src/main/res/layout/dialog_mic_select.xml
Normal file
40
app/src/main/res/layout/dialog_mic_select.xml
Normal file
@@ -0,0 +1,40 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout 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="@drawable/bg_000000_topr16">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/title"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:paddingVertical="15dp"
|
||||
android:text="@string/up_mic"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="16dp"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/confirm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingHorizontal="15dp"
|
||||
android:paddingVertical="15dp"
|
||||
android:text="@string/ok"
|
||||
android:textColor="#ff8c03"
|
||||
android:textSize="16sp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/title"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/title" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rvList"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="15dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/title" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
18
app/src/main/res/layout/dialog_user_card_item_new.xml
Normal file
18
app/src/main/res/layout/dialog_user_card_item_new.xml
Normal file
@@ -0,0 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
tools:layout_width="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="38dp"
|
||||
android:layout_height="38dp"
|
||||
android:layout_gravity="center_horizontal|top"
|
||||
android:layout_marginHorizontal="13dp"
|
||||
android:layout_marginBottom="12dp" />
|
||||
|
||||
</FrameLayout>
|
@@ -1,402 +1,439 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="330dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:orientation="vertical"
|
||||
tools:background="#000">
|
||||
android:background="@color/transparent"
|
||||
android:clipChildren="false"
|
||||
android:clipToPadding="false"
|
||||
tools:background="#2233">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
<!--
|
||||
userCardWearLayout
|
||||
iv_avatar_bg
|
||||
transition_mask
|
||||
iv_user_card_wear
|
||||
iv_user_card_wear_mp4
|
||||
-->
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/userCarRootLayout"
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="85dp"
|
||||
android:background="@drawable/bg_ffffff_r16"
|
||||
android:clipChildren="false"
|
||||
android:clipToPadding="false"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<!-- 顶部默认背景-->
|
||||
<View
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="110dp"
|
||||
android:layout_gravity="bottom|center_horizontal"
|
||||
android:background="@drawable/shape_white_top_10dp"/>
|
||||
|
||||
<!-- 用户装扮资料卡-->
|
||||
<FrameLayout
|
||||
android:id="@+id/userCardWearLayout"
|
||||
android:layout_width="330dp"
|
||||
android:layout_height="250dp"
|
||||
android:layout_marginTop="-85dp"
|
||||
android:clipChildren="false"
|
||||
android:clipToPadding="false"
|
||||
android:visibility="invisible"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
<!-- 用户没有装扮时 加载 头像为背景-->
|
||||
<com.makeramen.roundedimageview.RoundedImageView
|
||||
android:id="@+id/iv_avatar_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="180dp"
|
||||
tools:visibility="visible"
|
||||
tools:background="@drawable/bg_user_card_wear" />
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginBottom="-48dp"
|
||||
android:scaleType="center"
|
||||
android:visibility="visible"
|
||||
app:layout_constraintBottom_toBottomOf="@id/fl_avatar_layout"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:riv_corner_radius_top_left="16dp"
|
||||
app:riv_corner_radius_top_right="16dp"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_02"
|
||||
tools:src="@drawable/bg_login"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
<com.coorchice.library.SuperTextView
|
||||
android:id="@+id/transition_mask"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:visibility="invisible"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/iv_avatar_bg"
|
||||
app:layout_constraintTop_toTopOf="@+id/iv_avatar_bg"
|
||||
app:solid="@color/black_transparent_10"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/layout_userinfo"
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="110dp"
|
||||
android:layout_gravity="bottom|center_horizontal">
|
||||
|
||||
|
||||
<!-- 用户没有装扮时 加载 头像为背景-->
|
||||
<com.makeramen.roundedimageview.RoundedImageView
|
||||
android:id="@+id/iv_avatar_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="center"
|
||||
android:src="@drawable/shape_white_top_10dp"
|
||||
android:visibility="invisible"
|
||||
app:riv_corner_radius_top_left="@dimen/dp_10"
|
||||
app:riv_corner_radius_top_right="@dimen/dp_10"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_02" />
|
||||
|
||||
<com.coorchice.library.SuperTextView
|
||||
android:id="@+id/transition_mask"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:corner="@dimen/dp_10"
|
||||
app:left_bottom_corner="false"
|
||||
android:visibility="invisible"
|
||||
app:left_top_corner="true"
|
||||
app:right_bottom_corner="false"
|
||||
app:right_top_corner="true"
|
||||
app:solid="@color/black_transparent_10" />
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_avatar_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginStart="@dimen/dp_10"
|
||||
android:paddingTop="@dimen/dp_10">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="55dp"
|
||||
android:layout_gravity="center" />
|
||||
|
||||
<com.chwl.library.widget.SVGAView
|
||||
android:id="@+id/iv_avatar_head_wear"
|
||||
android:layout_width="73dp"
|
||||
android:layout_height="73dp"
|
||||
android:layout_gravity="center" />
|
||||
</FrameLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_nick_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginStart="2dp"
|
||||
android:layout_toEndOf="@id/fl_avatar_layout"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="@dimen/dp_10">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/dp_3"
|
||||
android:gravity="center_vertical"
|
||||
android:maxWidth="165dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_vip_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@drawable/ic_user_charm_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/nick"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:ellipsize="end"
|
||||
android:maxWidth="100dp"
|
||||
android:maxLength="10"
|
||||
android:maxLines="1"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_14"
|
||||
tools:text="@string/layout_dialog_user_info_03" />
|
||||
|
||||
<com.chwl.app.view.GenderAgeTextView
|
||||
android:id="@+id/tv_gender_age"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/dp_3"
|
||||
android:textSize="@dimen/sp_11" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/layout_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_04">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_badge"
|
||||
android:layout_width="@dimen/dp_13"
|
||||
android:layout_height="@dimen/dp_13"
|
||||
android:layout_marginEnd="5dp"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level_king"
|
||||
tools:visibility="gone" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/in_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_5"
|
||||
android:visibility="gone"
|
||||
tools:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:adjustViewBounds="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_temp_official_mask" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_official_mask"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="22dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:gravity="center"
|
||||
android:includeFontPadding="false"
|
||||
android:singleLine="true"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="11dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="@+id/iv_official_mask"
|
||||
app:layout_constraintStart_toStartOf="@id/iv_official_mask"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:text="@string/layout_dialog_user_info_05" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_level"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_charm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<include
|
||||
android:id="@+id/inNameplateVip"
|
||||
layout="@layout/layout_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:visibility="visible" />
|
||||
|
||||
<include
|
||||
android:id="@+id/in_nameplate"
|
||||
layout="@layout/layout_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_official"
|
||||
android:layout_width="@dimen/dp_10"
|
||||
android:layout_height="@dimen/dp_10"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_user_official_10dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_new_user"
|
||||
android:layout_width="@dimen/dp_10"
|
||||
android:layout_height="@dimen/dp_10"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_user_new_10dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_good_number"
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_good_num"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_erban_id"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/white_transparent_50"
|
||||
android:textSize="@dimen/sp_12"
|
||||
tools:text="ID123456" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_copy"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_4"
|
||||
android:src="@drawable/ic_room_user_copy" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_family"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="5dp"
|
||||
android:orientation="horizontal"
|
||||
android:visibility="gone">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_family_name_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/family_user_card_label"
|
||||
android:textColor="@color/white_transparent_50"
|
||||
android:textSize="@dimen/sp_13" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_family_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_13"
|
||||
tools:text="@string/empty_family_text" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_report"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignTop="@+id/close_image"
|
||||
android:layout_marginEnd="@dimen/dp_5"
|
||||
android:layout_toStartOf="@+id/close_image"
|
||||
android:gravity="center"
|
||||
android:paddingStart="@dimen/dp_5"
|
||||
android:paddingEnd="@dimen/dp_5"
|
||||
android:text="@string/layout_dialog_user_info_06"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_12" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/close_image"
|
||||
android:layout_width="@dimen/dp_19"
|
||||
android:layout_height="@dimen/dp_19"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginEnd="@dimen/dp_4"
|
||||
android:scaleType="fitCenter"
|
||||
android:src="@drawable/icon_close_user_dialog" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
<!-- 旧版 mp4 资料卡背景 -->
|
||||
<ImageView
|
||||
<!-- 旧版 mp4 资料卡背景 -->
|
||||
<com.makeramen.roundedimageview.RoundedImageView
|
||||
android:id="@+id/iv_user_card_wear"
|
||||
android:layout_width="match_parent"
|
||||
tools:visibility="gone"
|
||||
android:layout_height="180dp"
|
||||
tools:background="@drawable/bg_user_card_wear" />
|
||||
android:layout_height="0dp"
|
||||
android:scaleType="fitXY"
|
||||
android:visibility="invisible"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/iv_avatar_bg"
|
||||
app:layout_constraintTop_toTopOf="@+id/iv_avatar_bg"
|
||||
app:riv_corner_radius_top_left="16dp"
|
||||
app:riv_corner_radius_top_right="16dp"
|
||||
tools:src="@drawable/bg_login"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<com.tencent.qgame.animplayer.AnimView
|
||||
android:id="@+id/iv_user_card_wear_mp4"
|
||||
android:layout_width="match_parent"
|
||||
tools:visibility="gone"
|
||||
android:layout_width="330dp"
|
||||
android:layout_height="180dp"
|
||||
tools:background="@drawable/bg_user_card_wear" />
|
||||
android:layout_marginTop="20dp"
|
||||
android:clipChildren="false"
|
||||
android:clipToPadding="false"
|
||||
android:visibility="visible"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/userCardWearLayout"
|
||||
tools:background="@drawable/bg_user_card_wear"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/fans_number"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:textColor="@color/color_A3A3A3"
|
||||
android:textSize="13dp"
|
||||
android:visibility="gone"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_07"
|
||||
tools:text="@string/layout_dialog_user_info_08" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:background="@drawable/bg_user_info_dialog_bottom"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recyclerview_skill_card"
|
||||
android:layout_width="match_parent"
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_avatar_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="12dp"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_marginEnd="12dp"
|
||||
android:layout_marginBottom="@dimen/dp_8" />
|
||||
android:layout_marginTop="27dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="75dp"
|
||||
android:layout_height="75dp"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/default_avatar" />
|
||||
|
||||
<com.chwl.library.widget.SVGAView
|
||||
android:id="@+id/iv_avatar_head_wear"
|
||||
android:layout_width="105dp"
|
||||
android:layout_height="105dp"
|
||||
android:layout_gravity="center" />
|
||||
</FrameLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/layout_grid_button"
|
||||
android:layout_width="match_parent"
|
||||
android:id="@+id/infoLayout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
android:layout_below="@id/fl_avatar_layout"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="@+id/fl_avatar_layout"
|
||||
app:layout_constraintStart_toStartOf="@+id/fl_avatar_layout"
|
||||
app:layout_constraintTop_toBottomOf="@+id/fl_avatar_layout">
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
android:id="@+id/flexbox"
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/nick"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:ellipsize="end"
|
||||
android:maxWidth="100dp"
|
||||
android:maxLength="10"
|
||||
android:maxLines="1"
|
||||
android:textColor="@color/color_313131"
|
||||
android:textSize="@dimen/sp_14"
|
||||
tools:text="@string/layout_dialog_user_info_03" />
|
||||
|
||||
<com.chwl.app.view.GenderAgeTextView
|
||||
android:id="@+id/tv_gender_age"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/dp_3"
|
||||
android:textSize="@dimen/sp_11" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_official"
|
||||
android:layout_width="14dp"
|
||||
android:layout_height="14dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_user_official_13dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_new_user"
|
||||
android:layout_width="14dp"
|
||||
android:layout_height="14dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@drawable/ic_new_user"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_good_number"
|
||||
android:layout_width="14dp"
|
||||
android:layout_height="14dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_good_num"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_erban_id"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#7b7b7d"
|
||||
android:textSize="@dimen/sp_12"
|
||||
tools:text="ID123456" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_copy"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_4"
|
||||
android:src="@drawable/ic_room_user_copy"
|
||||
app:tint="#7b7b7d" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/layout_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="6dp"
|
||||
android:orientation="horizontal"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_04">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_vip_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@drawable/ic_user_charm_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_badge"
|
||||
android:layout_width="@dimen/dp_13"
|
||||
android:layout_height="@dimen/dp_13"
|
||||
android:layout_marginEnd="5dp"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level_king"
|
||||
tools:visibility="gone" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/in_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_5"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:adjustViewBounds="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_temp_official_mask" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_official_mask"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="22dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:gravity="center"
|
||||
android:includeFontPadding="false"
|
||||
android:singleLine="true"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="11dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="@+id/iv_official_mask"
|
||||
app:layout_constraintStart_toStartOf="@id/iv_official_mask"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:text="@string/layout_dialog_user_info_05" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_level"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_charm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<include
|
||||
android:id="@+id/inNameplateVip"
|
||||
layout="@layout/layout_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:visibility="visible" />
|
||||
|
||||
<include
|
||||
android:id="@+id/in_nameplate"
|
||||
layout="@layout/layout_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_family"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:orientation="horizontal"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_family_name_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/family_user_card_label"
|
||||
android:textColor="@color/white_transparent_50"
|
||||
android:textSize="@dimen/sp_13" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_family_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_13"
|
||||
tools:text="@string/empty_family_text" />
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recyclerview_skill_card"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
app:flexWrap="wrap" />
|
||||
android:layout_marginStart="12dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:layout_marginEnd="12dp"
|
||||
android:layout_marginBottom="@dimen/dp_8" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycler_view_mic"
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/btnLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
android:visibility="gone">
|
||||
android:layout_marginHorizontal="26dp"
|
||||
android:layout_marginTop="12dp"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintTop_toBottomOf="@id/infoLayout">
|
||||
|
||||
</androidx.recyclerview.widget.RecyclerView>
|
||||
<ImageView
|
||||
android:id="@+id/gift"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@drawable/icon_send_gift_ture"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintEnd_toStartOf="@+id/send"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/send"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@mipmap/ic_private_chat"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintEnd_toStartOf="@id/aite"
|
||||
app:layout_constraintStart_toEndOf="@+id/gift"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/aite"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@drawable/icon_dialog_ait"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintEnd_toStartOf="@id/follow"
|
||||
app:layout_constraintStart_toEndOf="@id/send"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/follow"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@drawable/icon_dialog_cancel_attent"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@id/aite"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
android:id="@+id/flexbox"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="15dp"
|
||||
android:layout_marginTop="24dp"
|
||||
android:minWidth="285dp"
|
||||
app:flexWrap="wrap"
|
||||
app:layout_constraintTop_toBottomOf="@id/btnLayout"
|
||||
tools:layout_height="20dp" />
|
||||
|
||||
<View
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginTop="-12dp"
|
||||
android:background="#e4e4e4"
|
||||
app:layout_constraintTop_toTopOf="@id/flexbox" />
|
||||
|
||||
<com.coorchice.library.SuperTextView
|
||||
android:id="@+id/tv_select_him"
|
||||
@@ -413,12 +450,29 @@
|
||||
android:textSize="13sp"
|
||||
android:visibility="gone"
|
||||
app:corner="15dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/flexbox"
|
||||
app:shaderEnable="true"
|
||||
app:shaderEndColor="#FA4771"
|
||||
app:shaderMode="leftToRight"
|
||||
app:shaderStartColor="#FA7187"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
android:id="@+id/tv_report"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/layout_dialog_user_info_06"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_12"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
424
app/src/main/res/layout/item_mic_select.xml
Normal file
424
app/src/main/res/layout/item_mic_select.xml
Normal file
@@ -0,0 +1,424 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="330dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:orientation="vertical"
|
||||
tools:background="#000">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- 顶部默认背景-->
|
||||
<View
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="110dp"
|
||||
android:layout_gravity="bottom|center_horizontal"
|
||||
android:background="@drawable/shape_white_top_10dp"/>
|
||||
|
||||
<!-- 用户装扮资料卡-->
|
||||
<FrameLayout
|
||||
android:id="@+id/userCardWearLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="180dp"
|
||||
tools:visibility="visible"
|
||||
tools:background="@drawable/bg_user_card_wear" />
|
||||
|
||||
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/layout_userinfo"
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="110dp"
|
||||
android:layout_gravity="bottom|center_horizontal">
|
||||
|
||||
|
||||
<!-- 用户没有装扮时 加载 头像为背景-->
|
||||
<com.makeramen.roundedimageview.RoundedImageView
|
||||
android:id="@+id/iv_avatar_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="center"
|
||||
android:src="@drawable/shape_white_top_10dp"
|
||||
android:visibility="invisible"
|
||||
app:riv_corner_radius_top_left="@dimen/dp_10"
|
||||
app:riv_corner_radius_top_right="@dimen/dp_10"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_02" />
|
||||
|
||||
<com.coorchice.library.SuperTextView
|
||||
android:id="@+id/transition_mask"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:corner="@dimen/dp_10"
|
||||
app:left_bottom_corner="false"
|
||||
android:visibility="invisible"
|
||||
app:left_top_corner="true"
|
||||
app:right_bottom_corner="false"
|
||||
app:right_top_corner="true"
|
||||
app:solid="@color/black_transparent_10" />
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_avatar_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginStart="@dimen/dp_10"
|
||||
android:paddingTop="@dimen/dp_10">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="55dp"
|
||||
android:layout_height="55dp"
|
||||
android:layout_gravity="center" />
|
||||
|
||||
<com.chwl.library.widget.SVGAView
|
||||
android:id="@+id/iv_avatar_head_wear"
|
||||
android:layout_width="73dp"
|
||||
android:layout_height="73dp"
|
||||
android:layout_gravity="center" />
|
||||
</FrameLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_nick_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginStart="2dp"
|
||||
android:layout_toEndOf="@id/fl_avatar_layout"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="@dimen/dp_10">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/dp_3"
|
||||
android:gravity="center_vertical"
|
||||
android:maxWidth="165dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_vip_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@drawable/ic_user_charm_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/nick"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:ellipsize="end"
|
||||
android:maxWidth="100dp"
|
||||
android:maxLength="10"
|
||||
android:maxLines="1"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_14"
|
||||
tools:text="@string/layout_dialog_user_info_03" />
|
||||
|
||||
<com.chwl.app.view.GenderAgeTextView
|
||||
android:id="@+id/tv_gender_age"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/dp_3"
|
||||
android:textSize="@dimen/sp_11" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/layout_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_04">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_badge"
|
||||
android:layout_width="@dimen/dp_13"
|
||||
android:layout_height="@dimen/dp_13"
|
||||
android:layout_marginEnd="5dp"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level_king"
|
||||
tools:visibility="gone" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/in_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_5"
|
||||
android:visibility="gone"
|
||||
tools:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:adjustViewBounds="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_temp_official_mask" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_official_mask"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="22dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:gravity="center"
|
||||
android:includeFontPadding="false"
|
||||
android:singleLine="true"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="11dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="@+id/iv_official_mask"
|
||||
app:layout_constraintStart_toStartOf="@id/iv_official_mask"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:text="@string/layout_dialog_user_info_05" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_level"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_charm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_user_level"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<include
|
||||
android:id="@+id/inNameplateVip"
|
||||
layout="@layout/layout_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:visibility="visible" />
|
||||
|
||||
<include
|
||||
android:id="@+id/in_nameplate"
|
||||
layout="@layout/layout_official_mask"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_20"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
android:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_user_official"
|
||||
android:layout_width="@dimen/dp_10"
|
||||
android:layout_height="@dimen/dp_10"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_user_official_10dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_new_user"
|
||||
android:layout_width="@dimen/dp_10"
|
||||
android:layout_height="@dimen/dp_10"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_user_new_10dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_good_number"
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_marginEnd="3dp"
|
||||
android:src="@mipmap/ic_good_num"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_erban_id"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/white_transparent_50"
|
||||
android:textSize="@dimen/sp_12"
|
||||
tools:text="ID123456" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/iv_copy"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_4"
|
||||
android:src="@drawable/ic_room_user_copy" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_family"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="5dp"
|
||||
android:orientation="horizontal"
|
||||
android:visibility="gone">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_family_name_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/family_user_card_label"
|
||||
android:textColor="@color/white_transparent_50"
|
||||
android:textSize="@dimen/sp_13" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_family_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_13"
|
||||
tools:text="@string/empty_family_text" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_report"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignTop="@+id/close_image"
|
||||
android:layout_marginEnd="@dimen/dp_5"
|
||||
android:layout_toStartOf="@+id/close_image"
|
||||
android:gravity="center"
|
||||
android:paddingStart="@dimen/dp_5"
|
||||
android:paddingEnd="@dimen/dp_5"
|
||||
android:text="@string/layout_dialog_user_info_06"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_12" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/close_image"
|
||||
android:layout_width="@dimen/dp_19"
|
||||
android:layout_height="@dimen/dp_19"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginEnd="@dimen/dp_4"
|
||||
android:scaleType="fitCenter"
|
||||
android:src="@drawable/icon_close_user_dialog" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
<!-- 旧版 mp4 资料卡背景 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_user_card_wear"
|
||||
android:layout_width="match_parent"
|
||||
tools:visibility="gone"
|
||||
android:layout_height="180dp"
|
||||
tools:background="@drawable/bg_user_card_wear" />
|
||||
<com.tencent.qgame.animplayer.AnimView
|
||||
android:id="@+id/iv_user_card_wear_mp4"
|
||||
android:layout_width="match_parent"
|
||||
tools:visibility="gone"
|
||||
android:layout_height="180dp"
|
||||
tools:background="@drawable/bg_user_card_wear" />
|
||||
|
||||
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/fans_number"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:textColor="@color/color_A3A3A3"
|
||||
android:textSize="13dp"
|
||||
android:visibility="gone"
|
||||
tools:contentDescription="@string/layout_dialog_user_info_07"
|
||||
tools:text="@string/layout_dialog_user_info_08" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="285dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:background="@drawable/bg_user_info_dialog_bottom"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recyclerview_skill_card"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="12dp"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_marginEnd="12dp"
|
||||
android:layout_marginBottom="@dimen/dp_8" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/layout_grid_button"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
android:id="@+id/flexbox"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
app:flexWrap="wrap" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycler_view_mic"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
android:visibility="gone">
|
||||
|
||||
</androidx.recyclerview.widget.RecyclerView>
|
||||
|
||||
<com.coorchice.library.SuperTextView
|
||||
android:id="@+id/tv_select_him"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="25dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginStart="70dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:layout_marginEnd="70dp"
|
||||
android:layout_marginBottom="15dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/layout_dialog_user_info_010"
|
||||
android:textColor="#FFFEFE"
|
||||
android:textSize="13sp"
|
||||
android:visibility="gone"
|
||||
app:corner="15dp"
|
||||
app:shaderEnable="true"
|
||||
app:shaderEndColor="#FA4771"
|
||||
app:shaderMode="leftToRight"
|
||||
app:shaderStartColor="#FA7187"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
@@ -1,26 +1,29 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="70dp"
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:layout_width="80dp">
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="14dp"
|
||||
tools:background="@color/black">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_mic"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:scaleType="fitXY" />
|
||||
android:layout_width="50dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_gravity="center"
|
||||
tools:src="@drawable/default_avatar" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_pos"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/color_999999"
|
||||
android:textSize="@dimen/sp_10"
|
||||
android:layout_below="@id/iv_mic"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="4dp"
|
||||
android:layout_centerHorizontal="true"
|
||||
tools:text="@string/layout_item_user_card_up_mic_01" />
|
||||
android:textColor="@color/white_transparent_80"
|
||||
android:textSize="12sp"
|
||||
tools:text="NO.1" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
</LinearLayout>
|
@@ -413,9 +413,6 @@ public final class AvRoomDataManager {
|
||||
isFirstFollow = true;
|
||||
}
|
||||
|
||||
public boolean isCpRoom() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getType() == RoomInfo.ROOMTYPE_CP;
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新在队列上的某个人ext字段,可以让它即时生效
|
||||
@@ -588,17 +585,6 @@ public final class AvRoomDataManager {
|
||||
return !isRoomAdmin(account) && !isRoomOwner(account);
|
||||
}
|
||||
|
||||
public boolean isOpenPKMode() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getRoomModeType() == RoomModeType.OPEN_PK_MODE;
|
||||
}
|
||||
|
||||
public boolean isOpenAnotherPKMode() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getRoomModeType() == RoomModeType.OPEN_ANOTHER_PK_MODE;
|
||||
}
|
||||
|
||||
public boolean isSingleRoom() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getType() == RoomInfo.ROOM_TYPE_SINGLE;
|
||||
}
|
||||
|
||||
public int getRoomType() {
|
||||
if (mCurrentRoomInfo == null) {
|
||||
@@ -1101,6 +1087,28 @@ public final class AvRoomDataManager {
|
||||
return roomInfo.hasDragonGame;
|
||||
}
|
||||
|
||||
public boolean isCpRoom() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getType() == RoomInfo.ROOMTYPE_CP;
|
||||
}
|
||||
public boolean isOpenPKMode() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getRoomModeType() == RoomModeType.OPEN_PK_MODE;
|
||||
}
|
||||
|
||||
public boolean isOpenAnotherPKMode() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getRoomModeType() == RoomModeType.OPEN_ANOTHER_PK_MODE;
|
||||
}
|
||||
|
||||
public boolean isSingleRoom() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getType() == RoomInfo.ROOM_TYPE_SINGLE;
|
||||
}
|
||||
public boolean isPartyRoom() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getType() == RoomInfo.ROOMTYPE_PARTY;
|
||||
}
|
||||
public boolean isRevelryRoom() {
|
||||
return mCurrentRoomInfo != null && mCurrentRoomInfo.getType() == RoomInfo.ROOMTYPE_REVELRY;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 是否开启排麦模式
|
||||
*
|
||||
|
@@ -16,6 +16,7 @@ import androidx.core.view.isVisible
|
||||
import com.chwl.library.BuildConfig
|
||||
import com.chwl.library.utils.ResUtil
|
||||
import com.chwl.library.utils.SizeUtils
|
||||
import com.example.lib_utils.AppUtils
|
||||
import com.example.lib_utils.UiUtils.isRtl
|
||||
import com.example.lib_utils.ktx.getString
|
||||
import com.hjq.toast.ToastUtils
|
||||
@@ -84,6 +85,9 @@ fun View.setRL() {
|
||||
}
|
||||
}
|
||||
|
||||
fun Int.toDP() : Int {
|
||||
return SizeUtils.dp2px(AppUtils.getApp().applicationContext,this.toFloat())
|
||||
}
|
||||
|
||||
|
||||
fun TextView.setString(strId:Int,vararg vars: Any) {
|
||||
|
Reference in New Issue
Block a user