1:修改进入房间更改火热值
This commit is contained in:
@@ -82,6 +82,10 @@ public class ConfirmDialog extends Dialog {
|
||||
|
||||
// 设置点击监听器
|
||||
btnPositive.setOnClickListener(v -> {
|
||||
if (countDownTimer != null) {
|
||||
countDownTimer.cancel(); // 取消倒计时
|
||||
countDownTimer = null;
|
||||
}
|
||||
if (positiveButtonClickListener != null) {
|
||||
positiveButtonClickListener.onClick(v);
|
||||
}
|
||||
|
||||
@@ -301,6 +301,9 @@ public abstract class BaseWheatView extends ConstraintLayout implements IBaseWhe
|
||||
|
||||
}
|
||||
|
||||
public void setCharm(String charm){
|
||||
mCharmView.setSex(pitBean.getSex(), pitBean.getUser_id(), charm, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 开始倒计时
|
||||
|
||||
@@ -378,8 +378,6 @@ public class MainActivity extends BaseMvpActivity<HomePresenter, ActivityMainBin
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
|
||||
LogUtils.e("isShow", CommonAppContext.getInstance().isShow ,CommonAppContext.getInstance().isPlaying,isTaskRoot());
|
||||
LogUtils.e("isShow2", CommonAppContext.getInstance().isShow ,CommonAppContext.getInstance().isPlaying,CommonAppContext.getInstance().wasInBackground());
|
||||
// if (isTaskRoot() &&CommonAppContext.getInstance().isPlaying && CommonAppContext.getInstance().isShow) {
|
||||
// ARouter.getInstance().build(ARouteConstants.ROOM_DETAILS).withString("form", "首页").withString("roomId", CommonAppContext.getInstance().playId).navigation();
|
||||
// return;
|
||||
|
||||
@@ -1192,38 +1192,6 @@ public class RoomActivity extends BaseMvpActivity<RoomPresenter, ActivityRoomBin
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// 在子线程中处理礼物特效播放
|
||||
// ThreadUtils.executeBySingle(new ThreadUtils.SimpleTask<Void>() {
|
||||
// @Override
|
||||
// public Void doInBackground() throws Throwable {
|
||||
// // 预处理礼物数据(如果需要)
|
||||
// LogUtils.d("@@@@doInBackground",Thread.currentThread().getName());
|
||||
// if ("mp4".equals(mBinding.svgaGift.getFileExtension(giftInfo.getPlay_image()))) {
|
||||
// mBinding.svgaGift.downloadAndPlayMp4(giftInfo.getPlay_image());
|
||||
// }
|
||||
// return null;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public void onSuccess(Void result) {
|
||||
// LogUtils.d("@@@@",Thread.currentThread().getName());
|
||||
//
|
||||
// // 在主线程中更新UI
|
||||
//// runOnUiThread(() -> {
|
||||
//// try {
|
||||
//// // 使用post方法确保在下一个消息循环中执行
|
||||
//// mBinding.svgaGift.post(() -> {
|
||||
//// mBinding.svgaGift.setSource(giftInfo.getPlay_image(), 2);
|
||||
//// });
|
||||
//// } catch (Exception e) {
|
||||
//// LogUtils.e("Error setting gift source: " + e.getMessage());
|
||||
//// }
|
||||
//// });
|
||||
// }
|
||||
// });
|
||||
|
||||
List<RoomPitBean> pitList = mRoomInfoResp.getRoom_info().getPit_list();
|
||||
if (pitList == null) return;
|
||||
|
||||
@@ -1233,15 +1201,20 @@ public class RoomActivity extends BaseMvpActivity<RoomPresenter, ActivityRoomBin
|
||||
String typeId = mRoomInfoResp.getRoom_info().getType_id();
|
||||
if ("2".equals(typeId)) {
|
||||
roomFragment.handleAuctionMessageEvent(messageEvent);
|
||||
return;
|
||||
} else if ("1".equals(typeId) || "4".equals(typeId) || "3".equals(typeId)) {
|
||||
String labelId = mRoomInfoResp.getRoom_info().getLabel_id();
|
||||
if ("2".equals(labelId)) {
|
||||
roomFragment.KtvFragmentEvent(messageEvent);
|
||||
return;
|
||||
} else if ("1".equals(labelId)) {
|
||||
roomFragment.SingSongEvent(messageEvent);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else if ("7".equals(typeId)) {
|
||||
else if ("7".equals(typeId)) {//交友房
|
||||
roomFragment.friendshipRoomFragmentEvent(messageEvent);
|
||||
return;
|
||||
// for (RoomPitBean roomPitBean : pitList) {
|
||||
// if (roomPitBean.getUser_id().equals(toUserInfo.getUser_id() + "")) {
|
||||
// roomPitBean.setCharm(toUserInfo.getCharm());
|
||||
|
||||
@@ -387,6 +387,65 @@ public class FriendshipRoomFragment extends BaseRoomFragment<FriendshipRoomPrese
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: 2025/9/12 更新火热值
|
||||
public void event1005(RoomMessageEvent messageEvent){
|
||||
RoomPitBean pitBean = mBinding.wheatView9.pitBean;
|
||||
if (pitBean.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
mBinding.wheatView9.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean1 = mBinding.wheatView10.pitBean;
|
||||
if (pitBean1.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean1.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
mBinding.wheatView10.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView10.setData(pitBean1);
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean2 = mBinding.wheatView1.pitBean;
|
||||
if (pitBean2.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean2.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView1.setData(pitBean2);
|
||||
mBinding.wheatView1.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean3 = mBinding.wheatView2.pitBean;
|
||||
if (pitBean3.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean3.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView2.setData(pitBean3);
|
||||
mBinding.wheatView2.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean4 = mBinding.wheatView3.pitBean;
|
||||
if (pitBean4.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean4.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView3.setData(pitBean4);
|
||||
mBinding.wheatView3.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean5 = mBinding.wheatView4.pitBean;
|
||||
if (pitBean5.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean5.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView4.setData(pitBean5);
|
||||
mBinding.wheatView4.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean6 = mBinding.wheatView5.pitBean;
|
||||
if (pitBean6.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean6.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView5.setData(pitBean6);
|
||||
mBinding.wheatView5.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
RoomPitBean pitBean7 = mBinding.wheatView6.pitBean;
|
||||
if (pitBean7.getUser_id().equals(messageEvent.getText().getToUserInfo().getUser_id()+"")) {
|
||||
pitBean7.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
// mBinding.wheatView6.setData(pitBean7);
|
||||
mBinding.wheatView6.setCharm(messageEvent.getText().getToUserInfo().getCharm());
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public void event1058(RoomMessageEvent messageEvent) {
|
||||
int type = messageEvent.getText().getType();
|
||||
RoomPitBean pitBean = mBinding.wheatView9.pitBean;
|
||||
|
||||
@@ -1017,6 +1017,7 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: 2025/9/12 交友房
|
||||
public void friendshipRoomFragmentEvent(RoomMessageEvent messageEvent) {
|
||||
FriendshipRoomFragment friendshipRoomFragment = (FriendshipRoomFragment) getChildFragmentManager()
|
||||
.findFragmentByTag(FriendshipRoomFragment.class.getSimpleName());
|
||||
@@ -1029,6 +1030,9 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
||||
case 1058:
|
||||
friendshipRoomFragment.event1058(messageEvent);
|
||||
break;
|
||||
case 1005:
|
||||
friendshipRoomFragment.event1005(messageEvent);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1044,43 +1048,6 @@ public class RoomFragment extends BaseMvpFragment<RoomPresenter, FragmentRoomBin
|
||||
cabinFragment.handleMsgType1028(messageEvent);
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: 2025/9/12 1058,在离线
|
||||
public void handleMsgType1058(RoomMessageEvent messageEvent) {
|
||||
String typeId = mRoomInfoResp.getRoom_info().getType_id();
|
||||
String labelId = mRoomInfoResp.getRoom_info().getLabel_id();
|
||||
|
||||
if ("7".equals(typeId)) {
|
||||
FriendshipRoomFragment friendshipRoomFragment = findFragmentByTag(FriendshipRoomFragment.class);
|
||||
if (friendshipRoomFragment != null && friendshipRoomFragment.isAdded()) {
|
||||
friendshipRoomFragment.upRoomInfo(mRoomInfoResp);
|
||||
}
|
||||
} else if ("2".equals(typeId)) {
|
||||
RoomAuctionFragment auctionRoomFragment = findFragmentByTag(RoomAuctionFragment.class);
|
||||
if (auctionRoomFragment != null && auctionRoomFragment.isAdded()) {
|
||||
auctionRoomFragment.upRoomInfo(mRoomInfoResp);
|
||||
}
|
||||
} else if ("1".equals(typeId) || "3".equals(typeId) || "4".equals(typeId)) {
|
||||
if ("2".equals(labelId)) {
|
||||
RoomKtvFragment roomKtvFragment = findFragmentByTag(RoomKtvFragment.class);
|
||||
if (roomKtvFragment != null && roomKtvFragment.isAdded()) {
|
||||
roomKtvFragment.upRoomInfo(mRoomInfoResp);
|
||||
}
|
||||
} else if ("1".equals(labelId)) {
|
||||
SingSongFragment singSongFragment = findFragmentByTag(SingSongFragment.class);
|
||||
if (singSongFragment != null && singSongFragment.isAdded()) {
|
||||
singSongFragment.upRoomInfo(mRoomInfoResp);
|
||||
}
|
||||
}
|
||||
} else if ("6".equals(typeId)) {
|
||||
RoomCabinFragment roomCabinFragment = findFragmentByTag(RoomCabinFragment.class);
|
||||
if (roomCabinFragment != null && roomCabinFragment.isAdded()) {
|
||||
roomCabinFragment.upRoomInfo(mRoomInfoResp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// TODO: 2025/8/30 Ktv模式
|
||||
public void KtvFragmentEvent(RoomMessageEvent messageEvent) {
|
||||
RoomKtvFragment ktvFragment = (RoomKtvFragment) getChildFragmentManager()
|
||||
|
||||
@@ -91,7 +91,8 @@ public class RevenueFragment extends BaseMvpFragment<RevenuePresenter, FragmentR
|
||||
mBinding.tv2.setText(sdf.format(startDate));
|
||||
Log.d("SelectedTime", "结束时间:" + sdf.format(endDate));
|
||||
mBinding.tv22.setText(sdf.format(endDate));
|
||||
MvpPre.getRevenueData("1","50",revenueType,mBinding.tv2.getText().toString(),mBinding.tv22.getText().toString(),type);
|
||||
page=1;
|
||||
MvpPre.getRevenueData(page+"","50",revenueType,mBinding.tv2.getText().toString(),mBinding.tv22.getText().toString(),type);
|
||||
});
|
||||
dialog.show(getParentFragmentManager(), "DoubleTimePicker");
|
||||
});
|
||||
|
||||
@@ -66,9 +66,9 @@
|
||||
android:src="@mipmap/data2" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- <androidx.core.widget.NestedScrollView-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="match_parent">-->
|
||||
<!-- <androidx.core.widget.NestedScrollView-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="match_parent">-->
|
||||
|
||||
<com.scwang.smartrefresh.layout.SmartRefreshLayout
|
||||
android:id="@+id/smart_refresh_layout"
|
||||
@@ -78,32 +78,31 @@
|
||||
app:srlEnableRefresh="true">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/revenue_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
android:layout_marginBottom="0dp"
|
||||
android:background="@color/color_FFF5F5F5"
|
||||
android:orientation="vertical"
|
||||
android:clipToPadding="false"
|
||||
android:paddingBottom="0dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:listitem="@layout/item_revenue" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_45" />
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</com.scwang.smartrefresh.layout.SmartRefreshLayout>
|
||||
<!-- </androidx.core.widget.NestedScrollView>-->
|
||||
<!-- </androidx.core.widget.NestedScrollView>-->
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
Reference in New Issue
Block a user