个人中心
This commit is contained in:
@@ -728,6 +728,10 @@
|
||||
android:name=".decoration.view.DecorationStoreActivity"
|
||||
android:screenOrientation="portrait"
|
||||
android:windowSoftInputMode="stateHidden|adjustResize" />
|
||||
<activity
|
||||
android:name=".ui.user.UserGiftActivity"
|
||||
android:screenOrientation="portrait"
|
||||
android:windowSoftInputMode="stateHidden|adjustResize" />
|
||||
<activity
|
||||
android:name=".friend.view.SelectFriendActivity"
|
||||
android:screenOrientation="portrait"
|
||||
|
@@ -23,7 +23,7 @@ public class CollectionRoomAdapter extends BaseQuickAdapter<CollectionRoomInfo.F
|
||||
protected void convert(BaseViewHolder helper, CollectionRoomInfo.FansRoomListBean item) {
|
||||
|
||||
helper.setText(R.id.tv_room_name,item.getRoomName())
|
||||
.setText(R.id.tv_room_id,"ID:"+item.getRoomUid())
|
||||
.setText(R.id.tv_room_id,"ID:"+item.getErbanNo())
|
||||
.setText(R.id.tv_room_online_num,item.getRoomOnlineNum() +"");
|
||||
ImageView imageView = helper.getView(R.id.rriv_room_img);
|
||||
ImageLoadUtilsV2.loadImage(imageView, item.getRoomAvatar());
|
||||
|
@@ -44,6 +44,15 @@ public class CollectionRoomInfo {
|
||||
private String roomName;
|
||||
private int roomOnlineNum;
|
||||
private int roomUid;
|
||||
private int erbanNo;
|
||||
|
||||
public int getErbanNo() {
|
||||
return erbanNo;
|
||||
}
|
||||
|
||||
public void setErbanNo(int erbanNo) {
|
||||
this.erbanNo = erbanNo;
|
||||
}
|
||||
|
||||
public int getRoomUid() {
|
||||
return roomUid;
|
||||
|
@@ -65,12 +65,7 @@ public class ShowPhotoActivity extends BaseActivity {
|
||||
}
|
||||
});
|
||||
|
||||
photoAdapter.setmImageOnclickListener(new PhotoAdapter.imageOnclickListener() {
|
||||
@Override
|
||||
public void onClick() {
|
||||
finish();
|
||||
}
|
||||
});
|
||||
photoAdapter.setmImageOnclickListener(() -> finish());
|
||||
}
|
||||
|
||||
private void initData() {
|
||||
|
@@ -0,0 +1,25 @@
|
||||
package com.yizhuan.erban.ui.user;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.yizhuan.erban.R;
|
||||
import com.yizhuan.erban.base.BaseActivity;
|
||||
|
||||
import butterknife.ButterKnife;
|
||||
import butterknife.Unbinder;
|
||||
|
||||
public class UserGiftActivity extends BaseActivity {
|
||||
|
||||
private UserInfoGiftFragment userInfoGiftFragment;
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_user_gift);
|
||||
|
||||
initTitleBar("礼物");
|
||||
userInfoGiftFragment = UserInfoGiftFragment.newInstance();
|
||||
getSupportFragmentManager().beginTransaction().replace(R.id.fl_gift_container, userInfoGiftFragment, "userInfoGiftFragment")
|
||||
.commit();
|
||||
}
|
||||
}
|
@@ -175,6 +175,7 @@ public class UserInfoActivity extends BaseBindingActivity<ActivityUserInfoBindin
|
||||
mBinding.ivUserBack.setOnClickListener(this);
|
||||
mBinding.ivEdit.setOnClickListener(this);
|
||||
mBinding.tvEdit.setOnClickListener(this);
|
||||
mBinding.tvGiftDetail.setOnClickListener(this);
|
||||
}
|
||||
|
||||
private void getUserInfo(){
|
||||
@@ -537,6 +538,10 @@ public class UserInfoActivity extends BaseBindingActivity<ActivityUserInfoBindin
|
||||
}
|
||||
break;
|
||||
|
||||
case R.id.tv_gift_detail:
|
||||
startActivity(new Intent(this,UserGiftActivity.class));
|
||||
break;
|
||||
|
||||
// /**************** 测试代码 **************/
|
||||
// AVRoomActivity.start(this, 91, mRoomInfo!!.type)
|
||||
}
|
||||
|
@@ -48,7 +48,6 @@ public class UserInfoGiftFragment extends BaseBindingFragment<FragmentUserInfoGi
|
||||
|
||||
private UserInfo userInfo;
|
||||
private long userId = 0;
|
||||
|
||||
private long time;
|
||||
|
||||
private List<UserInfoItem> userInfoItems = new ArrayList<>();
|
||||
@@ -91,9 +90,6 @@ public class UserInfoGiftFragment extends BaseBindingFragment<FragmentUserInfoGi
|
||||
|
||||
@Override
|
||||
public void initiate() {
|
||||
|
||||
initUserGiftItems();
|
||||
|
||||
mBinding.rvGift.setLayoutManager(new GridLayoutManager(mContext, 4));
|
||||
userGiftAdapter = new UserGiftAdapter(mContext, userInfoItems);
|
||||
userGiftAdapter.bindToRecyclerView(mBinding.rvGift);
|
||||
@@ -103,19 +99,12 @@ public class UserInfoGiftFragment extends BaseBindingFragment<FragmentUserInfoGi
|
||||
List<UserInfoItem> list = userGiftAdapter.getData();
|
||||
if (ListUtils.isListEmpty(list))
|
||||
return 4;
|
||||
|
||||
UserInfoItem userInfoItem = list.get(position);
|
||||
int type = userInfoItem.getItemType();
|
||||
if (type == UserInfoItem.TYPE_TITLE
|
||||
|| type == UserInfoItem.TYPE_MAGIC_ITEMS
|
||||
|| type == UserInfoItem.TYPE_RADISH_ITEMS
|
||||
|| type == UserInfoItem.TYPE_DIV
|
||||
|| type == UserInfoItem.TYPE_GIFT_EMPTY) {
|
||||
if (type == UserInfoItem.TYPE_DIV || type == UserInfoItem.TYPE_GIFT_EMPTY) {
|
||||
return 4;
|
||||
|
||||
} else
|
||||
return 1;
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
@@ -127,13 +116,6 @@ public class UserInfoGiftFragment extends BaseBindingFragment<FragmentUserInfoGi
|
||||
initData(userInfo);
|
||||
}
|
||||
|
||||
private void initUserGiftItems() {
|
||||
for (int i = 0; i < 7; i++) {
|
||||
UserInfoItem userInfoItem = new UserInfoItem(UserInfoItem.TYPE_NONE);
|
||||
userInfoItems.add(userInfoItem);
|
||||
}
|
||||
}
|
||||
|
||||
private void initData(UserInfo userInfo) {
|
||||
if (null != userInfo) {
|
||||
Log.i("UserInfoGiftFragment", "not null");
|
||||
@@ -141,41 +123,6 @@ public class UserInfoGiftFragment extends BaseBindingFragment<FragmentUserInfoGi
|
||||
return;
|
||||
}
|
||||
time = System.currentTimeMillis();
|
||||
// 获取魔法数据
|
||||
MagicModel.get().getTargetMagicWall(userId)
|
||||
.compose(bindUntilEvent(FragmentEvent.DESTROY_VIEW))
|
||||
.subscribe(new BeanObserver<List<MagicInfo>>() {
|
||||
@Override
|
||||
public void onErrorMsg(String error) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onSuccess(List<MagicInfo> magicInfos) {
|
||||
getMagicWallSuccessView(magicInfos);
|
||||
}
|
||||
});
|
||||
|
||||
RadishGiftModel.get().getRadishWall(userId)
|
||||
.subscribe(new SingleObserver<List<RadishWallInfo>>() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onSuccess(List<RadishWallInfo> radishWallInfos) {
|
||||
getRadishWallSuccess(radishWallInfos);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e) {
|
||||
getRadishWallSuccess(null);
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
UserModel.get().requestUserGiftWall(userId, 2)
|
||||
.compose(bindUntilEvent(FragmentEvent.DESTROY_VIEW))
|
||||
.subscribe(new BeanObserver<List<GiftWallInfo>>() {
|
||||
@@ -189,106 +136,25 @@ public class UserInfoGiftFragment extends BaseBindingFragment<FragmentUserInfoGi
|
||||
onRequestGiftWall(giftWallInfos);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
NobleInfo nobleInfo = userInfo.getNobleInfo();
|
||||
userGiftAdapter.setNoble(nobleInfo != null);
|
||||
userGiftAdapter.setmTextColor(ContextCompat.getColor(mContext, nobleInfo == null ? R.color.black : R.color.color_333333));
|
||||
} else {
|
||||
|
||||
Log.i("UserInfoGiftFragment", "null");
|
||||
}
|
||||
}
|
||||
|
||||
private void getRadishWallSuccess(List<RadishWallInfo> radishWallInfoList) {
|
||||
if (ListUtils.isListEmpty(radishWallInfoList))
|
||||
return;
|
||||
|
||||
int allMagicCounts = 0;
|
||||
for (RadishWallInfo magicInfo : radishWallInfoList) {
|
||||
allMagicCounts += magicInfo.getReceiveCount();
|
||||
}
|
||||
|
||||
GiftTitleInfo giftTitleInfo = new GiftTitleInfo();
|
||||
giftTitleInfo.setTitle("收到的萝卜礼物");
|
||||
giftTitleInfo.setNum(String.valueOf(allMagicCounts));
|
||||
UserInfoItem userInfoItemTitle = userInfoItems.get(3);
|
||||
userInfoItemTitle.setItemType(UserInfoItem.TYPE_TITLE);
|
||||
userInfoItemTitle.setData(giftTitleInfo);
|
||||
|
||||
UserInfoItem userInfoItemList = userInfoItems.get(4);
|
||||
userInfoItemList.setItemType(UserInfoItem.TYPE_RADISH_ITEMS);
|
||||
userInfoItemList.setData((ArrayList<RadishWallInfo>) radishWallInfoList);
|
||||
|
||||
UserInfoItem div = userInfoItems.get(5);
|
||||
div.setItemType(UserInfoItem.TYPE_DIV);
|
||||
|
||||
userGiftAdapter.notifyDataSetChanged();
|
||||
}
|
||||
|
||||
private void getMagicWallSuccessView(List<MagicInfo> magicInfoList) {
|
||||
if (ListUtils.isListEmpty(magicInfoList))
|
||||
return;
|
||||
|
||||
int allMagicCounts = 0;
|
||||
for (MagicInfo magicInfo : magicInfoList) {
|
||||
allMagicCounts += magicInfo.getAmount();
|
||||
}
|
||||
|
||||
GiftTitleInfo giftTitleInfo = new GiftTitleInfo();
|
||||
giftTitleInfo.setTitle("被施展的魔法");
|
||||
giftTitleInfo.setNum(String.valueOf(allMagicCounts));
|
||||
UserInfoItem userInfoItemTitle = userInfoItems.get(0);
|
||||
userInfoItemTitle.setItemType(UserInfoItem.TYPE_TITLE);
|
||||
userInfoItemTitle.setData(giftTitleInfo);
|
||||
|
||||
UserInfoItem userInfoItemList = userInfoItems.get(1);
|
||||
userInfoItemList.setItemType(UserInfoItem.TYPE_MAGIC_ITEMS);
|
||||
userInfoItemList.setData((ArrayList<MagicInfo>) magicInfoList);
|
||||
|
||||
UserInfoItem div = userInfoItems.get(2);
|
||||
div.setItemType(UserInfoItem.TYPE_DIV);
|
||||
|
||||
userGiftAdapter.notifyDataSetChanged();
|
||||
}
|
||||
|
||||
private void onRequestGiftWall(List<GiftWallInfo> giftWallInfoList) {
|
||||
if (userInfo == null) return;
|
||||
|
||||
// 刷新数据
|
||||
while (userInfoItems.size() > 7) {
|
||||
userInfoItems.remove(7);
|
||||
}
|
||||
|
||||
if (ListUtils.isListEmpty(giftWallInfoList)) {
|
||||
GiftTitleInfo giftTitleInfo = new GiftTitleInfo();
|
||||
giftTitleInfo.setTitle("收到的礼物");
|
||||
giftTitleInfo.setNum(String.valueOf(0));
|
||||
UserInfoItem userInfoItemTitle = userInfoItems.get(6);
|
||||
userInfoItemTitle.setItemType(UserInfoItem.TYPE_TITLE);
|
||||
userInfoItemTitle.setData(giftTitleInfo);
|
||||
|
||||
UserInfoItem userInfoItem = new UserInfoItem(UserInfoItem.TYPE_GIFT_EMPTY);
|
||||
userInfoItems.add(userInfoItem);
|
||||
|
||||
} else {
|
||||
int totalCount = 0;
|
||||
for (GiftWallInfo giftWallInfo : giftWallInfoList) {
|
||||
totalCount += giftWallInfo.getReciveCount();
|
||||
}
|
||||
|
||||
GiftTitleInfo giftTitleInfo = new GiftTitleInfo();
|
||||
giftTitleInfo.setTitle("收到的礼物");
|
||||
giftTitleInfo.setNum(String.valueOf(totalCount));
|
||||
UserInfoItem userInfoItemTitle = userInfoItems.get(6);
|
||||
userInfoItemTitle.setItemType(UserInfoItem.TYPE_TITLE);
|
||||
userInfoItemTitle.setData(giftTitleInfo);
|
||||
|
||||
for (GiftWallInfo giftWallInfo : giftWallInfoList) {
|
||||
UserInfoItem<GiftWallInfo> userInfoItem = new UserInfoItem<>(UserInfoItem.TYPE_GIFT_ITEM, giftWallInfo);
|
||||
userInfoItems.add(userInfoItem);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
userGiftAdapter.notifyDataSetChanged();
|
||||
|
@@ -20,18 +20,12 @@ import java.util.List;
|
||||
|
||||
public class UserGiftAdapter extends UserTabBaseAdapter {
|
||||
|
||||
private boolean isNoble;
|
||||
private int mTextColor;
|
||||
|
||||
public UserGiftAdapter(Context context, List<UserInfoItem> data) {
|
||||
super(context, data);
|
||||
|
||||
addItemType(UserInfoItem.TYPE_MAGIC_ITEMS, R.layout.layout_gift_gallery);
|
||||
addItemType(UserInfoItem.TYPE_RADISH_ITEMS, R.layout.layout_gift_gallery);
|
||||
addItemType(UserInfoItem.TYPE_GIFT_ITEM, R.layout.list_item_gift_wall_info);
|
||||
addItemType(UserInfoItem.TYPE_GIFT_EMPTY, R.layout.layout_gift_empty);
|
||||
|
||||
mTextColor = ContextCompat.getColor(mContext, R.color.black);
|
||||
|
||||
}
|
||||
|
||||
@@ -44,15 +38,6 @@ public class UserGiftAdapter extends UserTabBaseAdapter {
|
||||
super.convert(helper, item);
|
||||
|
||||
switch (item.getItemType()) {
|
||||
|
||||
case UserInfoItem.TYPE_MAGIC_ITEMS:
|
||||
setMagicGallery(helper, item);
|
||||
break;
|
||||
|
||||
case UserInfoItem.TYPE_RADISH_ITEMS:
|
||||
setRadishGallery(helper, item);
|
||||
break;
|
||||
|
||||
case UserInfoItem.TYPE_GIFT_ITEM:
|
||||
setGiftItem(helper, item);
|
||||
break;
|
||||
@@ -63,56 +48,17 @@ public class UserGiftAdapter extends UserTabBaseAdapter {
|
||||
|
||||
}
|
||||
|
||||
private void setMagicGallery(BaseViewHolder helper, UserInfoItem item) {
|
||||
ArrayList<MagicInfo> magicInfoList = (ArrayList<MagicInfo>) item.getData();
|
||||
|
||||
if (!ListUtils.isListEmpty(magicInfoList)) {
|
||||
RecyclerView recyclerView = helper.itemView.findViewById(R.id.recycler_view_magic_wall);
|
||||
recyclerView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.HORIZONTAL, false));
|
||||
|
||||
MyMagicWallAdapter mMagicListAdapter = new MyMagicWallAdapter();
|
||||
mMagicListAdapter.bindToRecyclerView(recyclerView);
|
||||
|
||||
mMagicListAdapter.setNoble(isNoble);
|
||||
mMagicListAdapter.setNewData(magicInfoList);
|
||||
}
|
||||
}
|
||||
|
||||
private void setRadishGallery(BaseViewHolder helper, UserInfoItem item) {
|
||||
ArrayList<RadishWallInfo> magicInfoList = (ArrayList<RadishWallInfo>) item.getData();
|
||||
|
||||
if (!ListUtils.isListEmpty(magicInfoList)) {
|
||||
RecyclerView recyclerView = helper.itemView.findViewById(R.id.recycler_view_magic_wall);
|
||||
recyclerView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.HORIZONTAL, false));
|
||||
|
||||
RadishWallAdapter radishWallAdapter = new RadishWallAdapter();
|
||||
radishWallAdapter.bindToRecyclerView(recyclerView);
|
||||
|
||||
radishWallAdapter.setNewData(magicInfoList);
|
||||
}
|
||||
}
|
||||
|
||||
private void setGiftItem(BaseViewHolder helper, UserInfoItem item) {
|
||||
GiftWallInfo giftWallInfo = (GiftWallInfo) item.getData();
|
||||
|
||||
if (giftWallInfo != null) {
|
||||
|
||||
helper.setText(R.id.gift_name, giftWallInfo.getGiftName());
|
||||
helper.setText(R.id.gift_num, String.valueOf(giftWallInfo.getReciveCount()));
|
||||
helper.setTextColor(R.id.gift_name, mTextColor);
|
||||
helper.setTextColor(R.id.gift_num, mTextColor);
|
||||
helper.setText(R.id.gift_num, "x"+String.valueOf(giftWallInfo.getReciveCount()));
|
||||
|
||||
ImageView giftPic = helper.itemView.findViewById(R.id.gift_img);
|
||||
ImageLoadUtils.loadImage(mContext, giftWallInfo.getPicUrl(), giftPic);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public void setNoble(boolean noble) {
|
||||
isNoble = noble;
|
||||
}
|
||||
|
||||
public void setmTextColor(int mTextColor) {
|
||||
this.mTextColor = mTextColor;
|
||||
}
|
||||
}
|
||||
|
@@ -1,5 +1,6 @@
|
||||
package com.yizhuan.erban.ui.user.adapter;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.view.LayoutInflater;
|
||||
@@ -9,7 +10,10 @@ import android.widget.ImageView;
|
||||
|
||||
import com.jude.rollviewpager.adapter.StaticPagerAdapter;
|
||||
import com.yizhuan.erban.R;
|
||||
import com.yizhuan.erban.UIHelper;
|
||||
import com.yizhuan.erban.ui.setting.SettingActivity;
|
||||
import com.yizhuan.erban.ui.user.ShowPhotoActivity;
|
||||
import com.yizhuan.erban.ui.user.UserPhotoAdapter;
|
||||
import com.yizhuan.erban.ui.utils.ImageLoadUtils;
|
||||
import com.yizhuan.erban.utils.CommonJumpHelper;
|
||||
import com.yizhuan.xchat_android_core.home.bean.BannerInfo;
|
||||
@@ -45,7 +49,7 @@ public class UserInfoPhotoAdapter extends StaticPagerAdapter {
|
||||
if (photoInfo == null) return imgBanner;
|
||||
ImageLoadUtils.loadImage(context, photoInfo.getPhotoUrl(), imgBanner);
|
||||
imgBanner.setOnClickListener(v -> {
|
||||
showUserPhoto(position,photoBeanList);
|
||||
showUserPhoto(position);
|
||||
});
|
||||
return imgBanner;
|
||||
}
|
||||
@@ -60,12 +64,13 @@ public class UserInfoPhotoAdapter extends StaticPagerAdapter {
|
||||
this.photoBeanList = bannerInfos;
|
||||
}
|
||||
|
||||
private void showUserPhoto(int position,List<UserDetailInfo.DataBean.PrivatePhotoBean> photoBeanList) {
|
||||
|
||||
private void showUserPhoto(int position) {
|
||||
//创建一个集合拿来做用户所有照片信息
|
||||
ArrayList<UserDetailInfo.DataBean.PrivatePhotoBean> userPhotos = new ArrayList<>();
|
||||
for (UserDetailInfo.DataBean.PrivatePhotoBean photo: photoBeanList) {
|
||||
UserDetailInfo.DataBean.PrivatePhotoBean newPhoto = new UserDetailInfo.DataBean.PrivatePhotoBean();
|
||||
newPhoto.setPhotoUrl(photo.getPhotoUrl());
|
||||
ArrayList<UserPhoto> userPhotos = new ArrayList<>();
|
||||
for (int i = 0 ; i < photoBeanList.size() ; i++) {
|
||||
UserPhoto newPhoto = new UserPhoto();
|
||||
newPhoto.setPhotoUrl(photoBeanList.get(i).getPhotoUrl());
|
||||
userPhotos.add(newPhoto);
|
||||
}
|
||||
Intent intent = new Intent(context, ShowPhotoActivity.class);
|
||||
|
@@ -2,8 +2,8 @@
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<solid android:color="#EFEBFF"/>
|
||||
<corners android:topLeftRadius="7.5dp"
|
||||
<corners android:topLeftRadius="8dp"
|
||||
android:topRightRadius="@dimen/dp_4"
|
||||
android:bottomRightRadius="7.5dp"
|
||||
android:bottomLeftRadius="7.5dp"/>
|
||||
android:bottomRightRadius="8dp"
|
||||
android:bottomLeftRadius="8dp"/>
|
||||
</shape>
|
21
app/src/main/res/layout/activity_user_gift.xml
Normal file
21
app/src/main/res/layout/activity_user_gift.xml
Normal file
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<com.yizhuan.erban.base.TitleBar
|
||||
android:id="@+id/title_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"/>
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_gift_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/title_bar"
|
||||
app:layout_constraintBottom_toBottomOf="parent"/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
@@ -193,16 +193,17 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_corner_shadow_12"
|
||||
android:padding="@dimen/dp_15"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<TextView
|
||||
android:id="@+id/tv_gift_detail"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="礼物"
|
||||
android:padding="@dimen/dp_15"
|
||||
android:textSize="@dimen/sp_13"
|
||||
android:textColor="@color/color_333333"
|
||||
android:drawableEnd="@drawable/arrow_right_2"
|
||||
@@ -212,6 +213,9 @@
|
||||
android:id="@+id/rv_gift"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
/>
|
||||
|
||||
</LinearLayout>
|
||||
|
@@ -3,5 +3,5 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="fitXY" />
|
||||
android:scaleType="centerCrop" />
|
||||
|
||||
|
@@ -5,9 +5,17 @@
|
||||
|
||||
</data>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_gift"
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
android:layout_height="match_parent"
|
||||
|
||||
>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_gift"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
</layout>
|
||||
|
@@ -4,8 +4,8 @@
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/gift_empty"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="250dp"
|
||||
android:gravity="center_horizontal"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical"
|
||||
android:visibility="visible">
|
||||
|
||||
|
@@ -4,31 +4,37 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:paddingStart="@dimen/dp_15"
|
||||
android:paddingEnd="@dimen/dp_15"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/gift_img"
|
||||
android:layout_width="60dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp"
|
||||
android:layout_marginTop="15dp" />
|
||||
android:layout_marginTop="10dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/gift_num"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="-10dp"
|
||||
android:textColor="@color/appColor"
|
||||
android:textSize="12dp"
|
||||
android:gravity="center"
|
||||
android:background="@drawable/bg_user_gift_count"
|
||||
tools:text="x120" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/gift_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="10dp"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="12sp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:textColor="@color/color_333333"
|
||||
android:textSize="13dp"
|
||||
tools:text="天使" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/gift_num"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="5dp"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="12sp"
|
||||
tools:text="x120" />
|
||||
|
||||
</LinearLayout>
|
Reference in New Issue
Block a user