修复:单人PK,PK条主播端和用户端展示问题
This commit is contained in:
parent
e030db04b9
commit
b804c20ba0
@ -10,9 +10,9 @@ ext {
|
|||||||
manifestPlaceholders = [
|
manifestPlaceholders = [
|
||||||
//正式
|
//正式
|
||||||
|
|
||||||
// serverHost : "https://napi.yaoulive.com",
|
serverHost : "https://napi.yaoulive.com",
|
||||||
// 測試
|
// 測試
|
||||||
serverHost : "https://ceshi.yaoulive.com",
|
// serverHost : "https://ceshi.yaoulive.com",
|
||||||
|
|
||||||
//腾讯地图
|
//腾讯地图
|
||||||
txMapAppKey : "EOZBZ-ASLCU-4XPV3-BDCHZ-4E3Q7-H4BWB",
|
txMapAppKey : "EOZBZ-ASLCU-4XPV3-BDCHZ-4E3Q7-H4BWB",
|
||||||
|
Binary file not shown.
@ -242,6 +242,7 @@ public class LiveAudienceEvent extends BaseModel {
|
|||||||
LEAVE_PK_SCORE(47, "PK排名"),
|
LEAVE_PK_SCORE(47, "PK排名"),
|
||||||
PK_TIME_COUNT(48, "多人PK结束"),
|
PK_TIME_COUNT(48, "多人PK结束"),
|
||||||
DISCONNEXT_PK_TIME(50, "单人Pk结束"),
|
DISCONNEXT_PK_TIME(50, "单人Pk结束"),
|
||||||
|
UP_PK_TWO(51, "PK头像信息"),
|
||||||
CUSTOM_FULL_SERVICE_NOTIFY(51, "全服通知");
|
CUSTOM_FULL_SERVICE_NOTIFY(51, "全服通知");
|
||||||
|
|
||||||
private int type;
|
private int type;
|
||||||
|
@ -111,7 +111,6 @@ public class LiveLinkMicPkPresenter implements View.OnClickListener {
|
|||||||
mIsAnchor = isAnchor;
|
mIsAnchor = isAnchor;
|
||||||
mRoot = root;
|
mRoot = root;
|
||||||
mPkContainer = linkMicViewHolder.getPkContainer();
|
mPkContainer = linkMicViewHolder.getPkContainer();
|
||||||
// mPkTimeString1 = WordUtil.getString(R.string.live_pk_time_1);
|
|
||||||
mPkTimeString2 = WordUtil.getString(R.string.live_pk_time_2);
|
mPkTimeString2 = WordUtil.getString(R.string.live_pk_time_2);
|
||||||
|
|
||||||
//从本地取数据
|
//从本地取数据
|
||||||
|
@ -867,6 +867,7 @@ public class LiveRyLinkMicPkPresenter implements View.OnClickListener {
|
|||||||
LivePushRyViewHolder.btn_close.setVisibility(View.VISIBLE);
|
LivePushRyViewHolder.btn_close.setVisibility(View.VISIBLE);
|
||||||
SocketRyLinkMicPkUtil.linkMicPkAccept(mSocketRyClient, mApplyUid, mApplyUrl, mApplyNmae);
|
SocketRyLinkMicPkUtil.linkMicPkAccept(mSocketRyClient, mApplyUid, mApplyUrl, mApplyNmae);
|
||||||
onLinkMicPkStart(mApplyUid, 2);
|
onLinkMicPkStart(mApplyUid, 2);
|
||||||
|
EventBus.getDefault().post(new LiveAudienceEvent().setType(LiveAudienceEvent.LiveAudienceType.UP_PK_TWO));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -994,6 +995,7 @@ public class LiveRyLinkMicPkPresenter implements View.OnClickListener {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(io.rong.imlib.model.Message message) {
|
public void onSuccess(io.rong.imlib.model.Message message) {
|
||||||
|
|
||||||
Log.e("ry", "发送成功");
|
Log.e("ry", "发送成功");
|
||||||
if (SocketRyClient.mSocketHandler != null) {
|
if (SocketRyClient.mSocketHandler != null) {
|
||||||
SocketRyClient.mSocketHandler.processBroadcast(msg1.mResult.toString() + "");
|
SocketRyClient.mSocketHandler.processBroadcast(msg1.mResult.toString() + "");
|
||||||
@ -1860,6 +1862,7 @@ public class LiveRyLinkMicPkPresenter implements View.OnClickListener {
|
|||||||
if (mPkPopWindow != null) {
|
if (mPkPopWindow != null) {
|
||||||
mPkPopWindow.dismiss();
|
mPkPopWindow.dismiss();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -1957,7 +1960,6 @@ public class LiveRyLinkMicPkPresenter implements View.OnClickListener {
|
|||||||
|
|
||||||
}
|
}
|
||||||
mLiveLinkMicPkViewHolder.startAnim();
|
mLiveLinkMicPkViewHolder.startAnim();
|
||||||
EventBus.getDefault().post(new LiveAudienceEvent().setType(LiveAudienceEvent.LiveAudienceType.PK_TWO_START).setObject(pkUid));
|
|
||||||
mLiveLinkMicPkViewHolder.showTime();
|
mLiveLinkMicPkViewHolder.showTime();
|
||||||
nextPkTimeCountDown();
|
nextPkTimeCountDown();
|
||||||
if (mIsAnchor) {
|
if (mIsAnchor) {
|
||||||
|
@ -806,6 +806,7 @@ public class SocketClient {
|
|||||||
mListener.onLinkMicPkNotResponse();
|
mListener.onLinkMicPkNotResponse();
|
||||||
break;
|
break;
|
||||||
case 9://pk结束的回调
|
case 9://pk结束的回调
|
||||||
|
|
||||||
mListener.onLinkMicPkEnd(map.getString("win_uid"));
|
mListener.onLinkMicPkEnd(map.getString("win_uid"));
|
||||||
break;
|
break;
|
||||||
case 10://系统发起PK回调
|
case 10://系统发起PK回调
|
||||||
|
@ -1056,6 +1056,7 @@ public class SocketRyClient {
|
|||||||
break;
|
break;
|
||||||
case 4://所有人收到PK开始址的回调
|
case 4://所有人收到PK开始址的回调
|
||||||
// RandomPkManager.getInstance().setPkStatus(RandomPkManager.PK_STATUS_START);
|
// RandomPkManager.getInstance().setPkStatus(RandomPkManager.PK_STATUS_START);
|
||||||
|
EventBus.getDefault().post(new LiveAudienceEvent().setType(LiveAudienceEvent.LiveAudienceType.PK_TWO_START).setObject(map.getString("pkuid")));
|
||||||
mListener.onLinkMicPkStart(map.getString("pkuid"), map.getString("pkhead"), map.getString("pkname"), map.getString("is_ladders"));
|
mListener.onLinkMicPkStart(map.getString("pkuid"), map.getString("pkhead"), map.getString("pkname"), map.getString("is_ladders"));
|
||||||
break;
|
break;
|
||||||
case 5://PK时候断开连麦的回调
|
case 5://PK时候断开连麦的回调
|
||||||
|
@ -115,12 +115,6 @@ public class LiveLinkMicPkViewHolder extends AbsViewHolder {
|
|||||||
if (mPkProgressBar != null && mPkProgressBar.getVisibility() != View.VISIBLE) {
|
if (mPkProgressBar != null && mPkProgressBar.getVisibility() != View.VISIBLE) {
|
||||||
mPkProgressBar.setVisibility(View.VISIBLE);
|
mPkProgressBar.setVisibility(View.VISIBLE);
|
||||||
}
|
}
|
||||||
// if (mLeft != null) {
|
|
||||||
// mLeft.setBackground(null);
|
|
||||||
// }
|
|
||||||
// if (mRight != null) {
|
|
||||||
// mRight.setBackground(null);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
mAnimator1.setInterpolator(new AccelerateDecelerateInterpolator());
|
mAnimator1.setInterpolator(new AccelerateDecelerateInterpolator());
|
||||||
@ -373,34 +367,11 @@ public class LiveLinkMicPkViewHolder extends AbsViewHolder {
|
|||||||
img_pk_show_r.setBackgroundResource(R.mipmap.icon_pk_win);
|
img_pk_show_r.setBackgroundResource(R.mipmap.icon_pk_win);
|
||||||
}
|
}
|
||||||
LiveRoomViewHolder.pkEndList(result);
|
LiveRoomViewHolder.pkEndList(result);
|
||||||
// } else {
|
|
||||||
// //PK结束动画
|
|
||||||
// mResultImageView.setImageResource(result == 0 ? R.mipmap.icon_live_pk_result_ping : R.mipmap.icon_live_pk_result_win);
|
|
||||||
// mResultImageView.startAnimation(mEndAnim2);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// mEndAnim2 = new ScaleAnimation(0.2f, 1, 0.2f, 1, Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
|
|
||||||
// mEndAnim2.setDuration(500);
|
|
||||||
// mEndAnim2.setAnimationListener(new Animation.AnimationListener() {
|
|
||||||
// @Override
|
|
||||||
// public void onAnimationStart(Animation animation) {
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// @Override
|
|
||||||
// public void onAnimationEnd(Animation animation) {
|
|
||||||
// mEndAnimator3 = getEndValueAnimator(result);
|
|
||||||
// mEndAnimator3.start();
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// @Override
|
|
||||||
// public void onAnimationRepeat(Animation animation) {
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
mEndAnimator1.start();
|
mEndAnimator1.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -432,7 +403,7 @@ public class LiveLinkMicPkViewHolder extends AbsViewHolder {
|
|||||||
if (mFrameImageView.getVisibility() == View.VISIBLE) {
|
if (mFrameImageView.getVisibility() == View.VISIBLE) {
|
||||||
mFrameImageView.setVisibility(View.INVISIBLE);
|
mFrameImageView.setVisibility(View.INVISIBLE);
|
||||||
}
|
}
|
||||||
// if () {
|
|
||||||
img_pk_show_l.setVisibility(View.VISIBLE);
|
img_pk_show_l.setVisibility(View.VISIBLE);
|
||||||
img_pk_show_r.setVisibility(View.VISIBLE);
|
img_pk_show_r.setVisibility(View.VISIBLE);
|
||||||
if (result == 0) {
|
if (result == 0) {
|
||||||
@ -446,33 +417,10 @@ public class LiveLinkMicPkViewHolder extends AbsViewHolder {
|
|||||||
img_pk_show_r.setBackgroundResource(R.mipmap.icon_pk_win);
|
img_pk_show_r.setBackgroundResource(R.mipmap.icon_pk_win);
|
||||||
}
|
}
|
||||||
LiveRoomViewHolder.pkEndList(result);
|
LiveRoomViewHolder.pkEndList(result);
|
||||||
// } else {
|
|
||||||
// //PK结束动画
|
|
||||||
// mResultImageView.setImageResource(result == 0 ? R.mipmap.icon_live_pk_result_ping : R.mipmap.icon_live_pk_result_win);
|
|
||||||
// mResultImageView.startAnimation(mEndAnim2);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// mEndAnim2 = new ScaleAnimation(0.2f, 1, 0.2f, 1, Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
|
|
||||||
// mEndAnim2.setDuration(500);
|
|
||||||
// mEndAnim2.setAnimationListener(new Animation.AnimationListener() {
|
|
||||||
// @Override
|
|
||||||
// public void onAnimationStart(Animation animation) {
|
|
||||||
//
|
//
|
||||||
// }
|
|
||||||
//
|
|
||||||
// @Override
|
|
||||||
// public void onAnimationEnd(Animation animation) {
|
|
||||||
// mEndAnimator3 = getEndValueAnimator(result);
|
|
||||||
// mEndAnimator3.start();
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// @Override
|
|
||||||
// public void onAnimationRepeat(Animation animation) {
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
mEndAnimator1.start();
|
mEndAnimator1.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -486,9 +434,6 @@ public class LiveLinkMicPkViewHolder extends AbsViewHolder {
|
|||||||
if (mEndAnimator1 != null) {
|
if (mEndAnimator1 != null) {
|
||||||
mEndAnimator1.cancel();
|
mEndAnimator1.cancel();
|
||||||
}
|
}
|
||||||
// if (mEndAnim2 != null) {
|
|
||||||
// mEndAnim2.cancel();
|
|
||||||
// }
|
|
||||||
if (mFrameImageView != null) {
|
if (mFrameImageView != null) {
|
||||||
mFrameImageView.clearAnimation();
|
mFrameImageView.clearAnimation();
|
||||||
mFrameImageView.release();
|
mFrameImageView.release();
|
||||||
|
@ -1947,12 +1947,12 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
lt_pk_line.setVisibility(View.VISIBLE);
|
lt_pk_line.setVisibility(View.VISIBLE);
|
||||||
img_pk_fist_l.setBackgroundResource(R.mipmap.icon_red_no1);
|
img_pk_fist_l.setBackgroundResource(R.mipmap.icon_red_no1);
|
||||||
img_pk_fist_r.setBackgroundResource(R.mipmap.icon_blue_no1);
|
img_pk_fist_r.setBackgroundResource(R.mipmap.icon_blue_no1);
|
||||||
ImgLoader.display2((LiveActivity) Contexts, "", avatar_l1);
|
ImgLoader.display2(mContext, R.mipmap.icon_sofa_red, avatar_l1);
|
||||||
ImgLoader.display2((LiveActivity) Contexts, "", avatar_l2);
|
ImgLoader.display2(mContext, R.mipmap.icon_sofa_red, avatar_l2);
|
||||||
ImgLoader.display2((LiveActivity) Contexts, "", avatar_l3);
|
ImgLoader.display2((LiveActivity) Contexts, R.mipmap.icon_sofa_red, avatar_l3);
|
||||||
ImgLoader.display2((LiveActivity) Contexts, "", avatar_r1);
|
ImgLoader.display2((LiveActivity) Contexts, R.mipmap.icon_sofa_blue, avatar_r1);
|
||||||
ImgLoader.display2((LiveActivity) Contexts, "", avatar_r2);
|
ImgLoader.display2((LiveActivity) Contexts, R.mipmap.icon_sofa_blue, avatar_r2);
|
||||||
ImgLoader.display2((LiveActivity) Contexts, "", avatar_r3);
|
ImgLoader.display2((LiveActivity) Contexts, R.mipmap.icon_sofa_blue, avatar_r3);
|
||||||
|
|
||||||
uidL1 = "";
|
uidL1 = "";
|
||||||
uidL2 = "";
|
uidL2 = "";
|
||||||
@ -3818,6 +3818,9 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
case PK_TIME_COUNT:
|
case PK_TIME_COUNT:
|
||||||
endDRGif();
|
endDRGif();
|
||||||
break;
|
break;
|
||||||
|
case UP_PK_TWO:
|
||||||
|
UpPkTwo();
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -414,7 +414,7 @@
|
|||||||
android:layout_alignParentRight="true"
|
android:layout_alignParentRight="true"
|
||||||
android:layout_alignParentBottom="true"
|
android:layout_alignParentBottom="true"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:layout_marginRight="47dp"
|
android:layout_marginRight="5dp"
|
||||||
android:layout_marginBottom="40dp"
|
android:layout_marginBottom="40dp"
|
||||||
app:autoPlay="true" />
|
app:autoPlay="true" />
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user