观看时长问题修改
This commit is contained in:
parent
302b789970
commit
0dc1009661
@ -481,6 +481,7 @@ public class LiveNetManager {
|
|||||||
* @param liveUid
|
* @param liveUid
|
||||||
*/
|
*/
|
||||||
public void leaveRoomNew(String stream, String liveUid, HttpCallback<String> callback) {
|
public void leaveRoomNew(String stream, String liveUid, HttpCallback<String> callback) {
|
||||||
|
Log.e("观看时长","leaveRoomNew-----------------------"+liveUid);
|
||||||
API.get().pdLiveApi(mContext)
|
API.get().pdLiveApi(mContext)
|
||||||
.leaveRoomNew("g" + liveUid, stream)
|
.leaveRoomNew("g" + liveUid, stream)
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
|
@ -22,8 +22,6 @@ import com.opensource.svgaplayer.SVGADrawable;
|
|||||||
import com.opensource.svgaplayer.SVGAImageView;
|
import com.opensource.svgaplayer.SVGAImageView;
|
||||||
import com.opensource.svgaplayer.SVGAParser;
|
import com.opensource.svgaplayer.SVGAParser;
|
||||||
import com.opensource.svgaplayer.SVGAVideoEntity;
|
import com.opensource.svgaplayer.SVGAVideoEntity;
|
||||||
import com.tencent.imsdk.v2.V2TIMCallback;
|
|
||||||
import com.tencent.imsdk.v2.V2TIMManager;
|
|
||||||
import com.umeng.analytics.MobclickAgent;
|
import com.umeng.analytics.MobclickAgent;
|
||||||
import com.yunbao.common.CommonAppConfig;
|
import com.yunbao.common.CommonAppConfig;
|
||||||
import com.yunbao.common.Constants;
|
import com.yunbao.common.Constants;
|
||||||
@ -65,9 +63,6 @@ import java.net.URL;
|
|||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import io.rong.imlib.IRongCoreCallback;
|
|
||||||
import io.rong.imlib.IRongCoreEnum;
|
|
||||||
import io.rong.imlib.chatroom.base.RongChatRoomClient;
|
|
||||||
import pl.droidsonroids.gif.GifImageView;
|
import pl.droidsonroids.gif.GifImageView;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -637,6 +632,7 @@ public class LiveUserDialogFragment extends AbsDialogFragment implements View.On
|
|||||||
|
|
||||||
|
|
||||||
private void gotoLive(String live_id) {
|
private void gotoLive(String live_id) {
|
||||||
|
dismiss();
|
||||||
DialogUitl.showSimpleDialog(mContext, mContext.getString(R.string.party_studio), new DialogUitl.SimpleCallback() {
|
DialogUitl.showSimpleDialog(mContext, mContext.getString(R.string.party_studio), new DialogUitl.SimpleCallback() {
|
||||||
@Override
|
@Override
|
||||||
public void onConfirmClick(Dialog dialog, String content) {
|
public void onConfirmClick(Dialog dialog, String content) {
|
||||||
|
@ -1826,6 +1826,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
* 重置数据
|
* 重置数据
|
||||||
*/
|
*/
|
||||||
public void resetView() {
|
public void resetView() {
|
||||||
|
countdownHandler.removeCallbacks(countdownRunnable);
|
||||||
svgaImageViewHashMap.clear();
|
svgaImageViewHashMap.clear();
|
||||||
pa_pao_layout.removeAllViews();
|
pa_pao_layout.removeAllViews();
|
||||||
timeHandler.removeCallbacks(timeRunnable);
|
timeHandler.removeCallbacks(timeRunnable);
|
||||||
@ -5061,7 +5062,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
countdownHandler.post(countdownRunnable);
|
countdownHandler.post(countdownRunnable);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Log.e("多人Pk", "upDataPkScore mPkTimeCount:" +mPkTimeCount);
|
||||||
for (int i = 0; i < pkScores.size(); i++) {
|
for (int i = 0; i < pkScores.size(); i++) {
|
||||||
JSONObject score = pkScores.getJSONObject(i);
|
JSONObject score = pkScores.getJSONObject(i);
|
||||||
String userNiceName = score.getString("user_nicename");
|
String userNiceName = score.getString("user_nicename");
|
||||||
@ -5152,8 +5153,10 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
public void run() {
|
public void run() {
|
||||||
mPkTimeCount--;
|
mPkTimeCount--;
|
||||||
if (mPkTimeCount > 0) {//
|
if (mPkTimeCount > 0) {//
|
||||||
|
Log.e("多人Pk", "countdownRunnable mPkTimeCount:" +mPkTimeCount);
|
||||||
String s1 = StringUtil.getDurationText(mPkTimeCount * 1000);
|
String s1 = StringUtil.getDurationText(mPkTimeCount * 1000);
|
||||||
textTime.setText(String.format(mContext.getString(R.string.pk_time), s1));
|
textTime.setText(String.format(mContext.getString(R.string.pk_time), s1));
|
||||||
|
Log.e("多人Pk", "countdownRunnable s1:" +s1);
|
||||||
countdownHandler.postAtTime(countdownRunnable, getNextSecondTime());
|
countdownHandler.postAtTime(countdownRunnable, getNextSecondTime());
|
||||||
} else {
|
} else {
|
||||||
mPkTimeCount = 0;
|
mPkTimeCount = 0;
|
||||||
|
@ -242,15 +242,17 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void setGiftRemainingQuantity(String giftRemainingQuantity) {
|
public void setGiftRemainingQuantity(String giftRemainingQuantity) {
|
||||||
if (mLiveAudienceViewHolder!=null){
|
if (mLiveAudienceViewHolder != null) {
|
||||||
mLiveAudienceViewHolder.setGiftRemainingQuantity(giftRemainingQuantity);
|
mLiveAudienceViewHolder.setGiftRemainingQuantity(giftRemainingQuantity);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setHotNum(String hotNum) {
|
public void setHotNum(String hotNum) {
|
||||||
if (mLiveRoomViewHolder!=null){
|
if (mLiveRoomViewHolder != null) {
|
||||||
mLiveRoomViewHolder.setHotNum(hotNum);
|
mLiveRoomViewHolder.setHotNum(hotNum);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public PortraitLiveManager(Activity context, Intent intent) {
|
public PortraitLiveManager(Activity context, Intent intent) {
|
||||||
this.mContext = context;
|
this.mContext = context;
|
||||||
this.mIntent = intent;
|
this.mIntent = intent;
|
||||||
@ -447,6 +449,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
public void run() {
|
public void run() {
|
||||||
//加入房间发送Im消息
|
//加入房间发送Im消息
|
||||||
LiveNetManager.get(mContext).userJoinRoomNew(mLiveBean.getStream(), mLiveBean.getUid());
|
LiveNetManager.get(mContext).userJoinRoomNew(mLiveBean.getStream(), mLiveBean.getUid());
|
||||||
|
Log.e("观看时长","userJoinRoomNew-----------------------"+mLiveBean.getUid());
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -459,6 +462,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
.enterRoomNew(mLiveBean.getStream(), mLiveBean.getUid(), mLiveBean.getCity(), new com.yunbao.common.http.base.HttpCallback<EnterRoomNewModel>() {
|
.enterRoomNew(mLiveBean.getStream(), mLiveBean.getUid(), mLiveBean.getCity(), new com.yunbao.common.http.base.HttpCallback<EnterRoomNewModel>() {
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(EnterRoomNewModel data) {
|
public void onSuccess(EnterRoomNewModel data) {
|
||||||
|
Log.e("观看时长","enterRoomNew-----------------------"+ mLiveBean.getUid());
|
||||||
isEnterRoom = true;
|
isEnterRoom = true;
|
||||||
if (TextUtils.isEmpty(leaveStream)) {
|
if (TextUtils.isEmpty(leaveStream)) {
|
||||||
leaveStream = mLiveBean.getStream();
|
leaveStream = mLiveBean.getStream();
|
||||||
@ -686,6 +690,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
}
|
}
|
||||||
|
|
||||||
upDataPkScore(pkInfo.getJSONArray("userlist"), pkInfo.getIntValue("drpk_time"));
|
upDataPkScore(pkInfo.getJSONArray("userlist"), pkInfo.getIntValue("drpk_time"));
|
||||||
|
Log.e("多人Pk", "enterRoomNew drpk_time:" + pkInfo.getIntValue("drpk_time"));
|
||||||
}
|
}
|
||||||
// mLivePlayViewHolder.setLayoutInterface(new LivePlayRyViewHolder.PlayViewLayoutInterface() {
|
// mLivePlayViewHolder.setLayoutInterface(new LivePlayRyViewHolder.PlayViewLayoutInterface() {
|
||||||
// @Override
|
// @Override
|
||||||
@ -808,7 +813,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onRemove(boolean isQuit) {
|
public void onRemove(boolean isQuit) {
|
||||||
Log.e("直播间接口调用排查","onRemove---------------");
|
Log.e("直播间接口调用排查", "onRemove---------------");
|
||||||
LiveNetManager.get(mContext).cancelLive();
|
LiveNetManager.get(mContext).cancelLive();
|
||||||
liveHandler.removeCallbacks(sendFIm);
|
liveHandler.removeCallbacks(sendFIm);
|
||||||
linkMicPkStartHandler.removeCallbacks(linkMicPkStartRunnable);
|
linkMicPkStartHandler.removeCallbacks(linkMicPkStartRunnable);
|
||||||
@ -1850,7 +1855,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
.leaveRoomNew(leaveStream, leaveGroupId, new com.yunbao.common.http.base.HttpCallback<String>() {
|
.leaveRoomNew(leaveStream, leaveGroupId, new com.yunbao.common.http.base.HttpCallback<String>() {
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(String data) {
|
public void onSuccess(String data) {
|
||||||
Log.e("直播间接口调用排查","leaveRoomNew---------------");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user