直播结束,悬浮窗
This commit is contained in:
parent
780f9a3328
commit
47b6f9b45f
@ -187,4 +187,6 @@ dependencies {
|
|||||||
api 'com.google.firebase:firebase-analytics:21.1.0'
|
api 'com.google.firebase:firebase-analytics:21.1.0'
|
||||||
// api 'com.huawei.hms:push:4.0.2.300'
|
// api 'com.huawei.hms:push:4.0.2.300'
|
||||||
implementation 'com.github.tajchert:WaitingDots:0.6.1'
|
implementation 'com.github.tajchert:WaitingDots:0.6.1'
|
||||||
|
//悬浮窗
|
||||||
|
api 'com.github.princekin-f:EasyFloat:2.0.4'
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,12 @@
|
|||||||
package com.yunbao.live.bean;
|
package com.yunbao.common.bean;
|
||||||
|
|
||||||
import android.os.Parcel;
|
import android.os.Parcel;
|
||||||
import android.os.Parcelable;
|
import android.os.Parcelable;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
|
|
||||||
import com.alibaba.fastjson.annotation.JSONField;
|
import com.alibaba.fastjson.annotation.JSONField;
|
||||||
import com.yunbao.common.bean.WeekListBean;
|
import com.yunbao.common.R;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.R;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
@ -0,0 +1,50 @@
|
|||||||
|
package com.yunbao.common.event;
|
||||||
|
|
||||||
|
import com.yunbao.common.bean.BaseModel;
|
||||||
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 悬浮窗直播通知
|
||||||
|
*/
|
||||||
|
public class LiveFloatEvent extends BaseModel {
|
||||||
|
private LiveBean mLiveBean;
|
||||||
|
private int mLiveType;
|
||||||
|
private int mLiveSDK;
|
||||||
|
private int mLiveTypeVal;
|
||||||
|
|
||||||
|
public LiveBean getmLiveBean() {
|
||||||
|
return mLiveBean;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LiveFloatEvent setmLiveBean(LiveBean mLiveBean) {
|
||||||
|
this.mLiveBean = mLiveBean;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getmLiveType() {
|
||||||
|
return mLiveType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LiveFloatEvent setmLiveType(int mLiveType) {
|
||||||
|
this.mLiveType = mLiveType;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getmLiveSDK() {
|
||||||
|
return mLiveSDK;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LiveFloatEvent setmLiveSDK(int mLiveSDK) {
|
||||||
|
this.mLiveSDK = mLiveSDK;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getmLiveTypeVal() {
|
||||||
|
return mLiveTypeVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LiveFloatEvent setmLiveTypeVal(int mLiveTypeVal) {
|
||||||
|
this.mLiveTypeVal = mLiveTypeVal;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}
|
@ -7,6 +7,7 @@ import com.alibaba.android.arouter.launcher.ARouter;
|
|||||||
import com.yunbao.common.CommonAppConfig;
|
import com.yunbao.common.CommonAppConfig;
|
||||||
import com.yunbao.common.Constants;
|
import com.yunbao.common.Constants;
|
||||||
import com.yunbao.common.HtmlConfig;
|
import com.yunbao.common.HtmlConfig;
|
||||||
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by cxf on 2019/2/25.
|
* Created by cxf on 2019/2/25.
|
||||||
@ -26,6 +27,7 @@ public class RouteUtil {
|
|||||||
public static final String PATH_FACEBOOKACTIVITY = "/baidu/FacebookLoginActivity";
|
public static final String PATH_FACEBOOKACTIVITY = "/baidu/FacebookLoginActivity";
|
||||||
public static final String PATH_MAIN = "/main/MainActivity";
|
public static final String PATH_MAIN = "/main/MainActivity";
|
||||||
public static final String PATH_ENTRY = "/main/EntryActivity";
|
public static final String PATH_ENTRY = "/main/EntryActivity";
|
||||||
|
public static final String PATH_LIVE_AUDIENCE = "/live/LiveAudienceActivity";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 启动页
|
* 启动页
|
||||||
@ -112,6 +114,18 @@ public class RouteUtil {
|
|||||||
.navigation();
|
.navigation();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 打开直播页面
|
||||||
|
*/
|
||||||
|
public static void forwardLiveAudienceActivity(LiveBean mLiveBean, int mLiveType, int mLiveSDK, int mLiveTypeVal) {
|
||||||
|
ARouter.getInstance().build(PATH_LIVE_AUDIENCE)
|
||||||
|
.withParcelable(Constants.LIVE_BEAN, mLiveBean)
|
||||||
|
.withInt(Constants.LIVE_TYPE, mLiveType)
|
||||||
|
.withInt(Constants.LIVE_SDK, mLiveSDK)
|
||||||
|
.withInt(Constants.LIVE_TYPE_VAL, mLiveTypeVal)
|
||||||
|
.navigation();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 举报个人
|
* 举报个人
|
||||||
*/
|
*/
|
||||||
|
@ -31,7 +31,6 @@ import com.yunbao.common.event.FollowEvent;
|
|||||||
import com.yunbao.common.http.HttpCallback;
|
import com.yunbao.common.http.HttpCallback;
|
||||||
import com.yunbao.common.http.live.LiveNetManager;
|
import com.yunbao.common.http.live.LiveNetManager;
|
||||||
import com.yunbao.common.interfaces.KeyBoardHeightChangeListener;
|
import com.yunbao.common.interfaces.KeyBoardHeightChangeListener;
|
||||||
import com.yunbao.common.utils.Bus;
|
|
||||||
import com.yunbao.common.utils.KeyBoardHeightUtil2;
|
import com.yunbao.common.utils.KeyBoardHeightUtil2;
|
||||||
import com.yunbao.common.utils.L;
|
import com.yunbao.common.utils.L;
|
||||||
import com.yunbao.common.utils.ProcessImageUtil;
|
import com.yunbao.common.utils.ProcessImageUtil;
|
||||||
@ -41,7 +40,7 @@ import com.yunbao.common.utils.WordUtil;
|
|||||||
import com.yunbao.common.utils.formatBigNum;
|
import com.yunbao.common.utils.formatBigNum;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.bean.GuardUserBean;
|
import com.yunbao.live.bean.GuardUserBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveBuyGuardMsgBean;
|
import com.yunbao.live.bean.LiveBuyGuardMsgBean;
|
||||||
import com.yunbao.live.bean.LiveChatBean;
|
import com.yunbao.live.bean.LiveChatBean;
|
||||||
import com.yunbao.live.bean.LiveDanMuBean;
|
import com.yunbao.live.bean.LiveDanMuBean;
|
||||||
@ -68,7 +67,6 @@ import com.yunbao.live.dialog.LiveRedPackSendDialogFragment;
|
|||||||
import com.yunbao.live.dialog.LiveShareDialogFragment;
|
import com.yunbao.live.dialog.LiveShareDialogFragment;
|
||||||
import com.yunbao.live.dialog.LiveUserDialogFragment;
|
import com.yunbao.live.dialog.LiveUserDialogFragment;
|
||||||
import com.yunbao.live.dialog.LiveUserMoreDialogFragment;
|
import com.yunbao.live.dialog.LiveUserMoreDialogFragment;
|
||||||
import com.yunbao.live.event.LiveAudienceEvent;
|
|
||||||
import com.yunbao.live.http.LiveHttpConsts;
|
import com.yunbao.live.http.LiveHttpConsts;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveLinkMicAnchorPresenter;
|
import com.yunbao.live.presenter.LiveLinkMicAnchorPresenter;
|
||||||
|
@ -39,7 +39,7 @@ import com.yunbao.common.utils.LogUtil;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveGuardInfo;
|
import com.yunbao.live.bean.LiveGuardInfo;
|
||||||
import com.yunbao.live.bean.LiveKsyConfigBean;
|
import com.yunbao.live.bean.LiveKsyConfigBean;
|
||||||
import com.yunbao.live.dialog.LiveBeautyDialogFragment;
|
import com.yunbao.live.dialog.LiveBeautyDialogFragment;
|
||||||
@ -56,7 +56,6 @@ import com.yunbao.live.music.LiveMusicDialogFragment;
|
|||||||
import com.yunbao.live.presenter.LiveLinkMicAnchorPresenter;
|
import com.yunbao.live.presenter.LiveLinkMicAnchorPresenter;
|
||||||
import com.yunbao.live.presenter.LiveLinkMicPkPresenter;
|
import com.yunbao.live.presenter.LiveLinkMicPkPresenter;
|
||||||
import com.yunbao.live.presenter.LiveLinkMicPresenter;
|
import com.yunbao.live.presenter.LiveLinkMicPresenter;
|
||||||
import com.yunbao.live.socket.SocketChatUtil;
|
|
||||||
import com.yunbao.live.socket.SocketClient;
|
import com.yunbao.live.socket.SocketClient;
|
||||||
import com.yunbao.live.socket.SocketSendBean;
|
import com.yunbao.live.socket.SocketSendBean;
|
||||||
import com.yunbao.live.views.AbsLivePushViewHolder;
|
import com.yunbao.live.views.AbsLivePushViewHolder;
|
||||||
|
@ -21,12 +21,14 @@ import androidx.viewpager.widget.ViewPager;
|
|||||||
|
|
||||||
import com.adjust.sdk.Adjust;
|
import com.adjust.sdk.Adjust;
|
||||||
import com.adjust.sdk.AdjustEvent;
|
import com.adjust.sdk.AdjustEvent;
|
||||||
|
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||||
import com.alibaba.fastjson.JSON;
|
import com.alibaba.fastjson.JSON;
|
||||||
import com.alibaba.fastjson.JSONArray;
|
import com.alibaba.fastjson.JSONArray;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.blankj.utilcode.util.GsonUtils;
|
import com.blankj.utilcode.util.GsonUtils;
|
||||||
import com.facebook.appevents.AppEventsLogger;
|
import com.facebook.appevents.AppEventsLogger;
|
||||||
import com.google.firebase.analytics.FirebaseAnalytics;
|
import com.google.firebase.analytics.FirebaseAnalytics;
|
||||||
|
import com.lzf.easyfloat.EasyFloat;
|
||||||
import com.yunbao.common.CommonAppConfig;
|
import com.yunbao.common.CommonAppConfig;
|
||||||
import com.yunbao.common.Constants;
|
import com.yunbao.common.Constants;
|
||||||
import com.yunbao.common.HtmlConfig;
|
import com.yunbao.common.HtmlConfig;
|
||||||
@ -56,12 +58,13 @@ import com.yunbao.common.utils.DialogUitl;
|
|||||||
import com.yunbao.common.utils.GiftCacheUtil;
|
import com.yunbao.common.utils.GiftCacheUtil;
|
||||||
import com.yunbao.common.utils.L;
|
import com.yunbao.common.utils.L;
|
||||||
import com.yunbao.common.utils.ProcessResultUtil;
|
import com.yunbao.common.utils.ProcessResultUtil;
|
||||||
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.views.weight.VerticalViewPager;
|
import com.yunbao.common.views.weight.VerticalViewPager;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.adapter.VerticalPagerAdapter;
|
import com.yunbao.live.adapter.VerticalPagerAdapter;
|
||||||
import com.yunbao.live.bean.ImUserBean;
|
import com.yunbao.live.bean.ImUserBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveChatBean;
|
import com.yunbao.live.bean.LiveChatBean;
|
||||||
import com.yunbao.live.dialog.LiveFansFragment;
|
import com.yunbao.live.dialog.LiveFansFragment;
|
||||||
import com.yunbao.live.dialog.LiveGiftDialogFragment;
|
import com.yunbao.live.dialog.LiveGiftDialogFragment;
|
||||||
@ -94,7 +97,7 @@ import java.util.Map;
|
|||||||
* Created by cxf on 2018/10/10.
|
* Created by cxf on 2018/10/10.
|
||||||
* 看直播
|
* 看直播
|
||||||
*/
|
*/
|
||||||
|
@Route(path = RouteUtil.PATH_LIVE_AUDIENCE)
|
||||||
public class LiveAudienceActivity extends LiveActivity {
|
public class LiveAudienceActivity extends LiveActivity {
|
||||||
|
|
||||||
private static final String TAG = "LiveAudienceActivity";
|
private static final String TAG = "LiveAudienceActivity";
|
||||||
@ -170,6 +173,10 @@ public class LiveAudienceActivity extends LiveActivity {
|
|||||||
verticalViewPager = findViewById(R.id.view_pager);
|
verticalViewPager = findViewById(R.id.view_pager);
|
||||||
|
|
||||||
verticalViewPager.setEnableScroll(IMLoginManager.get(mContext).isSlide());
|
verticalViewPager.setEnableScroll(IMLoginManager.get(mContext).isSlide());
|
||||||
|
//判断是否有直播悬浮窗,有直接关闭
|
||||||
|
if (EasyFloat.isShow("LiveFloatView")){
|
||||||
|
EasyFloat.dismiss("LiveFloatView",true);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -303,9 +310,7 @@ public class LiveAudienceActivity extends LiveActivity {
|
|||||||
if (liveBean1 == null) {
|
if (liveBean1 == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
runOnUiThread(new Runnable() {
|
runOnUiThread(() -> {
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
mLiveSDK = liveSdk;
|
mLiveSDK = liveSdk;
|
||||||
mLiveType = liveType;
|
mLiveType = liveType;
|
||||||
mLiveTypeVal = liveTypeVal;
|
mLiveTypeVal = liveTypeVal;
|
||||||
@ -327,7 +332,6 @@ public class LiveAudienceActivity extends LiveActivity {
|
|||||||
//加载完页面后再后台静默下载礼物svga
|
//加载完页面后再后台静默下载礼物svga
|
||||||
downloadAllGift();
|
downloadAllGift();
|
||||||
over();
|
over();
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
@ -55,14 +55,13 @@ import com.yunbao.common.utils.ScreenDimenUtil;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveGuardInfo;
|
import com.yunbao.live.bean.LiveGuardInfo;
|
||||||
import com.yunbao.live.bean.LiveKsyConfigBean;
|
import com.yunbao.live.bean.LiveKsyConfigBean;
|
||||||
import com.yunbao.live.bean.LiveReceiveGiftBean;
|
import com.yunbao.live.bean.LiveReceiveGiftBean;
|
||||||
import com.yunbao.live.bean.WishlistModel;
|
import com.yunbao.live.bean.WishlistModel;
|
||||||
import com.yunbao.live.dialog.LiveBeautyDialogFragment;
|
import com.yunbao.live.dialog.LiveBeautyDialogFragment;
|
||||||
import com.yunbao.live.dialog.LiveLinkMicListDialogFragment;
|
import com.yunbao.live.dialog.LiveLinkMicListDialogFragment;
|
||||||
import com.yunbao.live.dialog.LiveMicUserDialogFragment;
|
|
||||||
import com.yunbao.live.dialog.LiveNewFunctionDialogFragment;
|
import com.yunbao.live.dialog.LiveNewFunctionDialogFragment;
|
||||||
import com.yunbao.live.dialog.LiveNewWishListDialogFragment;
|
import com.yunbao.live.dialog.LiveNewWishListDialogFragment;
|
||||||
import com.yunbao.live.dialog.LiveWishListDialogFragment4Audience;
|
import com.yunbao.live.dialog.LiveWishListDialogFragment4Audience;
|
||||||
|
@ -25,7 +25,7 @@ import com.yunbao.common.utils.RouteUtil;
|
|||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.adapter.SystemChatMessageAdapter;
|
import com.yunbao.live.adapter.SystemChatMessageAdapter;
|
||||||
import com.yunbao.live.bean.ImUserBean;
|
import com.yunbao.live.bean.ImUserBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.event.RecommendLiveRoomEvent;
|
import com.yunbao.live.event.RecommendLiveRoomEvent;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
@ -34,7 +34,7 @@ import com.yunbao.common.utils.L;
|
|||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.dialog.LiveUserDialogFragment;
|
import com.yunbao.live.dialog.LiveUserDialogFragment;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
|
@ -13,7 +13,7 @@ import android.widget.ImageView;
|
|||||||
|
|
||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -44,7 +44,7 @@ import com.yunbao.live.activity.LiveActivity;
|
|||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.LiveRyAnchorActivity;
|
import com.yunbao.live.activity.LiveRyAnchorActivity;
|
||||||
import com.yunbao.live.activity.ZhuangBanActivity;
|
import com.yunbao.live.activity.ZhuangBanActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
|
@ -16,7 +16,7 @@ import com.yunbao.common.http.live.LiveNetManager;
|
|||||||
import com.yunbao.common.utils.Bus;
|
import com.yunbao.common.utils.Bus;
|
||||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||||
import com.yunbao.live.adapter.FunGamesAdapter;
|
import com.yunbao.live.adapter.FunGamesAdapter;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.LiveAudienceEvent;
|
import com.yunbao.live.event.LiveAudienceEvent;
|
||||||
|
|
||||||
import org.greenrobot.eventbus.Subscribe;
|
import org.greenrobot.eventbus.Subscribe;
|
||||||
|
@ -43,7 +43,7 @@ import com.yunbao.live.R;
|
|||||||
import com.yunbao.live.activity.LiveActivity;
|
import com.yunbao.live.activity.LiveActivity;
|
||||||
import com.yunbao.live.activity.LiveReportActivity;
|
import com.yunbao.live.activity.LiveReportActivity;
|
||||||
import com.yunbao.live.bean.ImpressBean;
|
import com.yunbao.live.bean.ImpressBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.custom.MyTextView;
|
import com.yunbao.live.custom.MyTextView;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpConsts;
|
import com.yunbao.live.http.LiveHttpConsts;
|
||||||
|
@ -30,7 +30,7 @@ import com.yunbao.common.utils.DeviceUtils;
|
|||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.adapter.SidebarAdapter;
|
import com.yunbao.live.adapter.SidebarAdapter;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.LiveAudienceEvent;
|
import com.yunbao.live.event.LiveAudienceEvent;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
@ -5,7 +5,7 @@ import com.yunbao.common.bean.AiAutomaticSpeechModel;
|
|||||||
import com.yunbao.common.bean.AnchorRecommendItemModel;
|
import com.yunbao.common.bean.AnchorRecommendItemModel;
|
||||||
import com.yunbao.common.bean.BaseModel;
|
import com.yunbao.common.bean.BaseModel;
|
||||||
import com.yunbao.common.bean.MsgModel;
|
import com.yunbao.common.bean.MsgModel;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.OpenParametersModel;
|
import com.yunbao.live.bean.OpenParametersModel;
|
||||||
|
|
||||||
public class LiveAudienceEvent extends BaseModel {
|
public class LiveAudienceEvent extends BaseModel {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
package com.yunbao.live.event;
|
package com.yunbao.live.event;
|
||||||
|
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by cxf on 2019/6/27.
|
* Created by cxf on 2019/6/27.
|
||||||
|
@ -50,7 +50,7 @@ import com.yunbao.common.utils.ToastUtil;
|
|||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveGiftPrizePoolWinBean;
|
import com.yunbao.live.bean.LiveGiftPrizePoolWinBean;
|
||||||
import com.yunbao.live.bean.LiveLuckGiftWinBean;
|
import com.yunbao.live.bean.LiveLuckGiftWinBean;
|
||||||
import com.yunbao.live.bean.LiveReceiveGiftBean;
|
import com.yunbao.live.bean.LiveReceiveGiftBean;
|
||||||
|
@ -16,7 +16,7 @@ import com.yunbao.common.utils.MD5Util;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.LiveAudienceEvent;
|
import com.yunbao.live.event.LiveAudienceEvent;
|
||||||
import com.yunbao.live.http.LiveHttpConsts;
|
import com.yunbao.live.http.LiveHttpConsts;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
package com.yunbao.live.utils;
|
package com.yunbao.live.utils;
|
||||||
|
|
||||||
import com.yunbao.common.CommonAppConfig;
|
import com.yunbao.common.CommonAppConfig;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -152,14 +152,15 @@ public class LiveTextRender {
|
|||||||
String mContext = content;
|
String mContext = content;
|
||||||
for (String name : userNames) {
|
for (String name : userNames) {
|
||||||
name = "@" + name;
|
name = "@" + name;
|
||||||
while (mContext.contains(name) && !TextUtils.isEmpty(mContext)) {
|
if (mContext.contains(name) && !TextUtils.isEmpty(mContext)) {
|
||||||
int index = mContext.indexOf(name);
|
int index = mContext.indexOf(name);
|
||||||
int end = index + name.length();
|
int end = index + name.length();
|
||||||
|
startIndex = index + startIndex;
|
||||||
int endIndex = startIndex + name.length();
|
int endIndex = startIndex + name.length();
|
||||||
spannableStringBuilder.setSpan(new ForegroundColorSpan(Color.parseColor("#fffe9b")),
|
spannableStringBuilder.setSpan(new ForegroundColorSpan(Color.parseColor("#fffe9b")),
|
||||||
startIndex, endIndex, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
startIndex, endIndex, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||||
mContext = mContext.substring(end + 1, mContext.length());
|
mContext = mContext.substring(end, mContext.length());
|
||||||
startIndex = startIndex + end + 1;
|
startIndex = endIndex;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -376,7 +377,7 @@ public class LiveTextRender {
|
|||||||
}
|
}
|
||||||
textView.setText(builder);
|
textView.setText(builder);
|
||||||
}
|
}
|
||||||
}else {
|
} else {
|
||||||
ImgLoader.displayDrawable(context, levelBean.getThumb(), new ImgLoader.DrawableCallback() {
|
ImgLoader.displayDrawable(context, levelBean.getThumb(), new ImgLoader.DrawableCallback() {
|
||||||
@Override
|
@Override
|
||||||
public void onLoadSuccess(Drawable drawable) {
|
public void onLoadSuccess(Drawable drawable) {
|
||||||
|
@ -27,7 +27,6 @@ import com.yunbao.common.manager.IMLoginManager;
|
|||||||
import com.yunbao.common.utils.Bus;
|
import com.yunbao.common.utils.Bus;
|
||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.common.utils.StringUtil;
|
import com.yunbao.common.utils.StringUtil;
|
||||||
import com.yunbao.common.utils.ToastUtil;
|
|
||||||
import com.yunbao.common.views.AbsViewHolder;
|
import com.yunbao.common.views.AbsViewHolder;
|
||||||
import com.yunbao.common.views.weight.ClipPathCircleImage;
|
import com.yunbao.common.views.weight.ClipPathCircleImage;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
@ -35,7 +34,7 @@ import com.yunbao.live.activity.LiveAnchorActivity;
|
|||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.LiveRyAnchorActivity;
|
import com.yunbao.live.activity.LiveRyAnchorActivity;
|
||||||
import com.yunbao.live.adapter.SearchRecommendBodyAdapter;
|
import com.yunbao.live.adapter.SearchRecommendBodyAdapter;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.JumpUserHomeEvent;
|
import com.yunbao.live.event.JumpUserHomeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpConsts;
|
import com.yunbao.live.http.LiveHttpConsts;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
142
live/src/main/java/com/yunbao/live/views/LiveFloatView.java
Normal file
142
live/src/main/java/com/yunbao/live/views/LiveFloatView.java
Normal file
@ -0,0 +1,142 @@
|
|||||||
|
package com.yunbao.live.views;
|
||||||
|
|
||||||
|
import android.app.Activity;
|
||||||
|
import android.util.Log;
|
||||||
|
import android.view.Gravity;
|
||||||
|
import android.view.View;
|
||||||
|
|
||||||
|
import com.lzf.easyfloat.EasyFloat;
|
||||||
|
import com.lzf.easyfloat.enums.ShowPattern;
|
||||||
|
import com.lzf.easyfloat.interfaces.FloatCallbacks;
|
||||||
|
import com.lzf.easyfloat.interfaces.OnInvokeView;
|
||||||
|
import com.tencent.live2.V2TXLivePlayer;
|
||||||
|
import com.tencent.live2.impl.V2TXLivePlayerImpl;
|
||||||
|
import com.tencent.rtmp.ui.TXCloudVideoView;
|
||||||
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
|
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||||
|
import com.yunbao.live.R;
|
||||||
|
|
||||||
|
import kotlin.Unit;
|
||||||
|
import kotlin.jvm.functions.Function0;
|
||||||
|
import kotlin.jvm.functions.Function1;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 直播间悬浮窗管理
|
||||||
|
*/
|
||||||
|
public class LiveFloatView implements Function1<FloatCallbacks.Builder, Unit> {
|
||||||
|
|
||||||
|
private static LiveFloatView instance;
|
||||||
|
private LiveOnInvokeView liveOnInvokeView = null;
|
||||||
|
private Activity mContext;
|
||||||
|
private String url;
|
||||||
|
private LiveBean mLiveBean;
|
||||||
|
private int mLiveType;
|
||||||
|
private int mLiveSDK;
|
||||||
|
private int mLiveTypeVal;
|
||||||
|
private FloatCallbacks.Builder builder;
|
||||||
|
private String TAG = "LiveFloatView";
|
||||||
|
private V2TXLivePlayer mPlayer;
|
||||||
|
|
||||||
|
public static LiveFloatView getInstance() {
|
||||||
|
if (instance == null) {
|
||||||
|
instance = new LiveFloatView();
|
||||||
|
}
|
||||||
|
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void builderFloat(Activity mContext, String url) {
|
||||||
|
liveOnInvokeView = new LiveOnInvokeView();
|
||||||
|
this.mContext = mContext;
|
||||||
|
this.url = url;
|
||||||
|
EasyFloat.with(mContext)
|
||||||
|
.setTag(TAG)
|
||||||
|
.setLayout(R.layout.view_flaot_live, liveOnInvokeView)
|
||||||
|
.setShowPattern(ShowPattern.CURRENT_ACTIVITY)
|
||||||
|
.setGravity(Gravity.END | Gravity.CENTER_VERTICAL, 0, 200)
|
||||||
|
.registerCallback(this)
|
||||||
|
.show();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void builderSystemFloat(Activity mContext, String url) {
|
||||||
|
liveOnInvokeView = new LiveOnInvokeView();
|
||||||
|
this.mContext = mContext;
|
||||||
|
this.url = url;
|
||||||
|
EasyFloat.with(mContext)
|
||||||
|
.setTag(TAG)
|
||||||
|
.setLayout(R.layout.view_flaot_live, liveOnInvokeView)
|
||||||
|
.setShowPattern(ShowPattern.ALL_TIME)
|
||||||
|
.setGravity(Gravity.END | Gravity.CENTER_VERTICAL, 0, 200)
|
||||||
|
.registerCallback(this)
|
||||||
|
.show();
|
||||||
|
}
|
||||||
|
|
||||||
|
public LiveFloatView cacheLiveData(LiveBean mLiveBean, int mLiveType, int mLiveSDK, int mLiveTypeVal) {
|
||||||
|
this.mLiveBean = mLiveBean;
|
||||||
|
this.mLiveType = mLiveType;
|
||||||
|
this.mLiveSDK = mLiveSDK;
|
||||||
|
this.mLiveTypeVal = mLiveTypeVal;
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Unit invoke(FloatCallbacks.Builder builder) {
|
||||||
|
this.builder = builder;
|
||||||
|
builder.createResult((aBoolean, s, view) -> {
|
||||||
|
Log.e("LiveFloatView", "aBoolean:" + aBoolean + "---------------------s:" + s);
|
||||||
|
if (callback != null) {
|
||||||
|
callback.invoke(aBoolean);
|
||||||
|
}
|
||||||
|
builder.dismiss(new Function0<Unit>() {
|
||||||
|
@Override
|
||||||
|
public Unit invoke() {
|
||||||
|
if (mPlayer != null && mPlayer.isPlaying() == 1) {
|
||||||
|
mPlayer.stopPlay();
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return null;
|
||||||
|
});
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 悬浮窗布局管理
|
||||||
|
*/
|
||||||
|
private class LiveOnInvokeView implements OnInvokeView {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void invoke(View view) {
|
||||||
|
TXCloudVideoView videoView = view.findViewById(R.id.video_view);
|
||||||
|
mPlayer = new V2TXLivePlayerImpl(mContext);
|
||||||
|
mPlayer.setRenderView(videoView);
|
||||||
|
mPlayer.startPlay(url);
|
||||||
|
ViewClicksAntiShake.clicksAntiShake(view.findViewById(R.id.btn_close), new ViewClicksAntiShake.ViewClicksCallBack() {
|
||||||
|
@Override
|
||||||
|
public void onViewClicks() {
|
||||||
|
mPlayer.stopPlay();
|
||||||
|
EasyFloat.dismiss("LiveFloatView", true);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
ViewClicksAntiShake.clicksAntiShake(videoView, () -> {
|
||||||
|
mPlayer.stopPlay();
|
||||||
|
RouteUtil.forwardLiveAudienceActivity(mLiveBean, mLiveType, mLiveSDK, mLiveTypeVal);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private LiveFloatViewCallback callback;
|
||||||
|
|
||||||
|
public LiveFloatView setCallback(LiveFloatViewCallback callback) {
|
||||||
|
this.callback = callback;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface LiveFloatViewCallback {
|
||||||
|
void invoke(Boolean aBoolean);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -2,7 +2,7 @@ package com.yunbao.live.views;
|
|||||||
|
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
|
|
||||||
|
|
||||||
public interface LivePlayListener extends LiveActivityLifeCallback {
|
public interface LivePlayListener extends LiveActivityLifeCallback {
|
||||||
|
@ -42,6 +42,7 @@ import com.adjust.sdk.AdjustEvent;
|
|||||||
import com.alibaba.fastjson.JSON;
|
import com.alibaba.fastjson.JSON;
|
||||||
import com.alibaba.fastjson.JSONArray;
|
import com.alibaba.fastjson.JSONArray;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.blankj.utilcode.util.GsonUtils;
|
||||||
import com.bumptech.glide.Glide;
|
import com.bumptech.glide.Glide;
|
||||||
import com.bumptech.glide.load.DataSource;
|
import com.bumptech.glide.load.DataSource;
|
||||||
import com.bumptech.glide.load.engine.GlideException;
|
import com.bumptech.glide.load.engine.GlideException;
|
||||||
@ -65,6 +66,7 @@ import com.yunbao.common.bean.BannerBean;
|
|||||||
import com.yunbao.common.bean.HourRank;
|
import com.yunbao.common.bean.HourRank;
|
||||||
import com.yunbao.common.bean.IMLoginModel;
|
import com.yunbao.common.bean.IMLoginModel;
|
||||||
import com.yunbao.common.bean.LevelBean;
|
import com.yunbao.common.bean.LevelBean;
|
||||||
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.common.bean.LiveGiftBean;
|
import com.yunbao.common.bean.LiveGiftBean;
|
||||||
import com.yunbao.common.bean.MsgModel;
|
import com.yunbao.common.bean.MsgModel;
|
||||||
import com.yunbao.common.bean.StarChallengeStatusModel;
|
import com.yunbao.common.bean.StarChallengeStatusModel;
|
||||||
@ -102,7 +104,6 @@ import com.yunbao.live.adapter.LiveChatAdapter;
|
|||||||
import com.yunbao.live.adapter.LiveRoomFastMessageRecyclerViewAdapter;
|
import com.yunbao.live.adapter.LiveRoomFastMessageRecyclerViewAdapter;
|
||||||
import com.yunbao.live.adapter.LiveUserAdapter;
|
import com.yunbao.live.adapter.LiveUserAdapter;
|
||||||
import com.yunbao.live.bean.DrPkbean;
|
import com.yunbao.live.bean.DrPkbean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
|
||||||
import com.yunbao.live.bean.LiveBuyGuardMsgBean;
|
import com.yunbao.live.bean.LiveBuyGuardMsgBean;
|
||||||
import com.yunbao.live.bean.LiveChatBean;
|
import com.yunbao.live.bean.LiveChatBean;
|
||||||
import com.yunbao.live.bean.LiveDanMuBean;
|
import com.yunbao.live.bean.LiveDanMuBean;
|
||||||
|
@ -30,17 +30,20 @@ import com.alibaba.fastjson.JSONArray;
|
|||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.blankj.utilcode.util.GsonUtils;
|
import com.blankj.utilcode.util.GsonUtils;
|
||||||
import com.facebook.appevents.AppEventsLogger;
|
import com.facebook.appevents.AppEventsLogger;
|
||||||
|
import com.lzf.easyfloat.permission.PermissionUtils;
|
||||||
import com.tencent.imsdk.v2.V2TIMCallback;
|
import com.tencent.imsdk.v2.V2TIMCallback;
|
||||||
import com.tencent.imsdk.v2.V2TIMManager;
|
import com.tencent.imsdk.v2.V2TIMManager;
|
||||||
import com.yunbao.common.CommonAppConfig;
|
import com.yunbao.common.CommonAppConfig;
|
||||||
import com.yunbao.common.CommonAppContext;
|
import com.yunbao.common.CommonAppContext;
|
||||||
import com.yunbao.common.Constants;
|
import com.yunbao.common.Constants;
|
||||||
import com.yunbao.common.bean.AiAutomaticSpeechModel;
|
import com.yunbao.common.bean.AiAutomaticSpeechModel;
|
||||||
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.common.bean.MsgModel;
|
import com.yunbao.common.bean.MsgModel;
|
||||||
import com.yunbao.common.bean.StarChallengeStatusModel;
|
import com.yunbao.common.bean.StarChallengeStatusModel;
|
||||||
import com.yunbao.common.bean.UserBean;
|
import com.yunbao.common.bean.UserBean;
|
||||||
import com.yunbao.common.custom.MyViewPager;
|
import com.yunbao.common.custom.MyViewPager;
|
||||||
import com.yunbao.common.event.FollowEvent;
|
import com.yunbao.common.event.FollowEvent;
|
||||||
|
import com.yunbao.common.event.LiveFloatEvent;
|
||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.common.http.CommonHttpConsts;
|
import com.yunbao.common.http.CommonHttpConsts;
|
||||||
import com.yunbao.common.http.CommonHttpUtil;
|
import com.yunbao.common.http.CommonHttpUtil;
|
||||||
@ -58,7 +61,6 @@ import com.yunbao.common.utils.formatBigNum;
|
|||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.activity.LiveActivity;
|
import com.yunbao.live.activity.LiveActivity;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
|
||||||
import com.yunbao.live.bean.LiveBuyGuardMsgBean;
|
import com.yunbao.live.bean.LiveBuyGuardMsgBean;
|
||||||
import com.yunbao.live.bean.LiveChatBean;
|
import com.yunbao.live.bean.LiveChatBean;
|
||||||
import com.yunbao.live.bean.LiveDanMuBean;
|
import com.yunbao.live.bean.LiveDanMuBean;
|
||||||
@ -216,8 +218,6 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
Log.e("ImgLoader1", data.getAvatar());
|
Log.e("ImgLoader1", data.getAvatar());
|
||||||
|
|
||||||
|
|
||||||
mLiveBean = data;
|
mLiveBean = data;
|
||||||
mLiveSDK = liveSdk;
|
mLiveSDK = liveSdk;
|
||||||
mLiveType = liveType;
|
mLiveType = liveType;
|
||||||
@ -228,12 +228,10 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
.setParametersModel(openParametersModel
|
.setParametersModel(openParametersModel
|
||||||
.setmLiveType(mLiveType)
|
.setmLiveType(mLiveType)
|
||||||
.setmLiveTypeVal(mLiveTypeVal)));
|
.setmLiveTypeVal(mLiveTypeVal)));
|
||||||
|
|
||||||
mLivePlayViewHolder = new LivePlayRyViewHolder(mContext, playContainer, mIntent.getIntExtra("landscape", 0));
|
mLivePlayViewHolder = new LivePlayRyViewHolder(mContext, playContainer, mIntent.getIntExtra("landscape", 0));
|
||||||
mLivePlayViewHolder.addToParent();
|
mLivePlayViewHolder.addToParent();
|
||||||
mLivePlayViewHolder.subscribeActivityLifeCycle();
|
mLivePlayViewHolder.subscribeActivityLifeCycle();
|
||||||
mLiveRoomViewHolder = new LiveRoomViewHolder(false, 1, mContext, mContainer, mSecondPage.findViewById(R.id.gift_gif), mSecondPage.findViewById(R.id.gift_svga), mContainerWrap, mContext.getWindowManager());
|
mLiveRoomViewHolder = new LiveRoomViewHolder(false, 1, mContext, mContainer, mSecondPage.findViewById(R.id.gift_gif), mSecondPage.findViewById(R.id.gift_svga), mContainerWrap, mContext.getWindowManager());
|
||||||
|
|
||||||
mLiveRoomViewHolder.subscribeActivityLifeCycle();
|
mLiveRoomViewHolder.subscribeActivityLifeCycle();
|
||||||
mLiveAudienceViewHolder = new LiveAudienceViewHolder(mContext, mContainer);
|
mLiveAudienceViewHolder = new LiveAudienceViewHolder(mContext, mContainer);
|
||||||
mLiveAudienceViewHolder.addToParent();
|
mLiveAudienceViewHolder.addToParent();
|
||||||
@ -368,8 +366,46 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
mLiveRyLinkMicPkPresenter.release();
|
mLiveRyLinkMicPkPresenter.release();
|
||||||
}
|
}
|
||||||
if (isQuit) {
|
if (isQuit) {
|
||||||
|
if (PermissionUtils.checkPermission(mContext)) {
|
||||||
|
|
||||||
|
} else {
|
||||||
if (mContext instanceof LiveAudienceActivity) {
|
if (mContext instanceof LiveAudienceActivity) {
|
||||||
|
DialogUitl.showSimpleDialog(mContext, null, "您未打开悬浮窗权限,是否打开", false, new DialogUitl.SimpleCallback3() {
|
||||||
|
@Override
|
||||||
|
public void onConfirmClick(Dialog dialog) {
|
||||||
|
LiveFloatView.getInstance()
|
||||||
|
.setCallback(new LiveFloatView.LiveFloatViewCallback() {
|
||||||
|
@Override
|
||||||
|
public void invoke(Boolean aBoolean) {
|
||||||
|
if (aBoolean) {
|
||||||
mContext.finish();
|
mContext.finish();
|
||||||
|
} else {
|
||||||
|
EventBus.getDefault()
|
||||||
|
.post(new LiveFloatEvent()
|
||||||
|
.setmLiveBean(mLiveBean)
|
||||||
|
.setmLiveSDK(mLiveSDK)
|
||||||
|
.setmLiveType(mLiveType)
|
||||||
|
.setmLiveTypeVal(mLiveTypeVal));
|
||||||
|
mContext.finish();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.cacheLiveData(mLiveBean, mLiveType, mLiveSDK, mLiveTypeVal)
|
||||||
|
.builderSystemFloat(mContext, mLiveBean.getPull());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCancel() {
|
||||||
|
EventBus.getDefault()
|
||||||
|
.post(new LiveFloatEvent()
|
||||||
|
.setmLiveBean(mLiveBean)
|
||||||
|
.setmLiveSDK(mLiveSDK)
|
||||||
|
.setmLiveType(mLiveType)
|
||||||
|
.setmLiveTypeVal(mLiveTypeVal));
|
||||||
|
mContext.finish();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -458,7 +494,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
Log.e("ry", "发送成功");
|
Log.e("ry", "发送成功");
|
||||||
liveImDeletUtil.deleteMessages(message.getTargetId(), message.getMessageId());
|
liveImDeletUtil.deleteMessages(message.getTargetId(), message.getMessageId());
|
||||||
if (isBackPressed) {
|
if (isBackPressed) {
|
||||||
((LiveAudienceActivity)mContext).closeRoom();
|
((LiveAudienceActivity) mContext).closeRoom();
|
||||||
} else {
|
} else {
|
||||||
EventBus.getDefault().post(new LiveRoomChangeEvent(bean, liveType, liveTypeVal));
|
EventBus.getDefault().post(new LiveRoomChangeEvent(bean, liveType, liveTypeVal));
|
||||||
}
|
}
|
||||||
@ -524,7 +560,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
|
|
||||||
if (isBackPressed) {
|
if (isBackPressed) {
|
||||||
Micing = 0;
|
Micing = 0;
|
||||||
((LiveAudienceActivity)mContext).closeRoom();
|
((LiveAudienceActivity) mContext).closeRoom();
|
||||||
} else {
|
} else {
|
||||||
EventBus.getDefault().post(new LiveRoomChangeEvent(bean, liveType, liveTypeVal));
|
EventBus.getDefault().post(new LiveRoomChangeEvent(bean, liveType, liveTypeVal));
|
||||||
}
|
}
|
||||||
@ -1475,8 +1511,9 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
|
|||||||
mLiveRoomViewHolder.playLightAnim();
|
mLiveRoomViewHolder.playLightAnim();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public void resetLight(){
|
|
||||||
mLighted=false;
|
public void resetLight() {
|
||||||
|
mLighted = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setCoinNotEnough(boolean coinNotEnough) {
|
public void setCoinNotEnough(boolean coinNotEnough) {
|
||||||
|
@ -15,7 +15,7 @@ import com.yunbao.common.utils.RouteUtil;
|
|||||||
import com.yunbao.common.views.SlideInBannerViewHolder;
|
import com.yunbao.common.views.SlideInBannerViewHolder;
|
||||||
import com.yunbao.live.R;
|
import com.yunbao.live.R;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
|
|
||||||
|
30
live/src/main/res/layout/view_flaot_live.xml
Normal file
30
live/src/main/res/layout/view_flaot_live.xml
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="210dp"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<androidx.cardview.widget.CardView
|
||||||
|
android:layout_width="200dp"
|
||||||
|
android:layout_height="150dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginEnd="10dp"
|
||||||
|
app:cardCornerRadius="4dp"
|
||||||
|
app:cardElevation="0dp">
|
||||||
|
|
||||||
|
<com.tencent.rtmp.ui.TXCloudVideoView
|
||||||
|
android:id="@+id/video_view"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent" />
|
||||||
|
</androidx.cardview.widget.CardView>
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/btn_close"
|
||||||
|
android:layout_width="50dp"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:layout_alignParentEnd="true"
|
||||||
|
android:paddingLeft="30dp"
|
||||||
|
android:paddingBottom="30dp"
|
||||||
|
android:src="@mipmap/icon_live_close_3" />
|
||||||
|
|
||||||
|
</RelativeLayout>
|
@ -42,8 +42,7 @@
|
|||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="right"
|
android:layout_gravity="right"
|
||||||
android:layout_marginBottom="20dp"
|
android:layout_marginBottom="20dp" />
|
||||||
/>
|
|
||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
@ -92,7 +92,7 @@ import com.yunbao.common.utils.RouteUtil;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
|
@ -13,7 +13,7 @@ import com.yunbao.common.custom.CommonRefreshView;
|
|||||||
import com.yunbao.common.custom.ItemDecoration;
|
import com.yunbao.common.custom.ItemDecoration;
|
||||||
import com.yunbao.common.http.HttpCallback;
|
import com.yunbao.common.http.HttpCallback;
|
||||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.utils.LiveStorge;
|
import com.yunbao.live.utils.LiveStorge;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.adapter.MainHomeFollowAdapter;
|
import com.yunbao.main.adapter.MainHomeFollowAdapter;
|
||||||
|
@ -46,7 +46,7 @@ import com.yunbao.common.manager.imrongcloud.RongcloudIMManager;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
|
@ -54,11 +54,13 @@ import com.yunbao.common.bean.AnchorRecommendModel;
|
|||||||
import com.yunbao.common.bean.ChatRemarksBean;
|
import com.yunbao.common.bean.ChatRemarksBean;
|
||||||
import com.yunbao.common.bean.ConfigBean;
|
import com.yunbao.common.bean.ConfigBean;
|
||||||
import com.yunbao.common.bean.IMLoginModel;
|
import com.yunbao.common.bean.IMLoginModel;
|
||||||
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.common.bean.LiveSvgGiftBean;
|
import com.yunbao.common.bean.LiveSvgGiftBean;
|
||||||
import com.yunbao.common.bean.UpdataListBean;
|
import com.yunbao.common.bean.UpdataListBean;
|
||||||
import com.yunbao.common.custom.TabButtonGroup;
|
import com.yunbao.common.custom.TabButtonGroup;
|
||||||
import com.yunbao.common.dialog.InstructorOperationDialog;
|
import com.yunbao.common.dialog.InstructorOperationDialog;
|
||||||
import com.yunbao.common.event.InstructorOperationEvent;
|
import com.yunbao.common.event.InstructorOperationEvent;
|
||||||
|
import com.yunbao.common.event.LiveFloatEvent;
|
||||||
import com.yunbao.common.event.MessageIMEvent;
|
import com.yunbao.common.event.MessageIMEvent;
|
||||||
import com.yunbao.common.event.NoviceInstructorEvent;
|
import com.yunbao.common.event.NoviceInstructorEvent;
|
||||||
import com.yunbao.common.event.RongIMConnectionStatusEvent;
|
import com.yunbao.common.event.RongIMConnectionStatusEvent;
|
||||||
@ -84,12 +86,12 @@ import com.yunbao.common.utils.WordUtil;
|
|||||||
import com.yunbao.common.views.AbsMainViewHolder;
|
import com.yunbao.common.views.AbsMainViewHolder;
|
||||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
|
||||||
import com.yunbao.live.http.LiveHttpConsts;
|
import com.yunbao.live.http.LiveHttpConsts;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
import com.yunbao.live.utils.LiveStorge;
|
import com.yunbao.live.utils.LiveStorge;
|
||||||
import com.yunbao.live.views.ChatListViewHolder;
|
import com.yunbao.live.views.ChatListViewHolder;
|
||||||
|
import com.yunbao.live.views.LiveFloatView;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.dialog.MainStartDialogFragment;
|
import com.yunbao.main.dialog.MainStartDialogFragment;
|
||||||
import com.yunbao.main.dialog.ReturnUserDialog;
|
import com.yunbao.main.dialog.ReturnUserDialog;
|
||||||
@ -1244,4 +1246,27 @@ public class MainActivity extends AbsActivity implements MainAppBarLayoutListene
|
|||||||
findViewById(R.id.banner_click).setVisibility(View.VISIBLE);
|
findViewById(R.id.banner_click).setVisibility(View.VISIBLE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||||
|
public void onLiveFloatEvent(LiveFloatEvent event) {
|
||||||
|
new Handler().postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
LiveFloatView.getInstance()
|
||||||
|
.setCallback(new LiveFloatView.LiveFloatViewCallback() {
|
||||||
|
@Override
|
||||||
|
public void invoke(Boolean aBoolean) {
|
||||||
|
// if (aBoolean) {
|
||||||
|
// mContext.finish();
|
||||||
|
// } else {
|
||||||
|
// ToastUtil.show("未打开悬浮窗权限");
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.cacheLiveData(event.getmLiveBean(), event.getmLiveType(), event.getmLiveSDK(), event.getmLiveTypeVal())
|
||||||
|
.builderFloat(mContext, event.getmLiveBean().getPull());
|
||||||
|
}
|
||||||
|
},1500);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -54,8 +54,7 @@ import com.yunbao.common.utils.ToastUtil;
|
|||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.LiveReportActivity;
|
import com.yunbao.live.activity.LiveReportActivity;
|
||||||
import com.yunbao.live.activity.PDLiveConversationActivity;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
|
||||||
import com.yunbao.live.bean.ReportCommunityBean;
|
import com.yunbao.live.bean.ReportCommunityBean;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
@ -41,7 +41,7 @@ import com.yunbao.common.utils.WordUtil;
|
|||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.LiveReportActivity;
|
import com.yunbao.live.activity.LiveReportActivity;
|
||||||
import com.yunbao.live.activity.SystemMessageActivity;
|
import com.yunbao.live.activity.SystemMessageActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.ReportCommunityBean;
|
import com.yunbao.live.bean.ReportCommunityBean;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
@ -54,7 +54,7 @@ import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
|||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.SystemMessageActivity;
|
import com.yunbao.live.activity.SystemMessageActivity;
|
||||||
import com.yunbao.live.bean.ImUserBean;
|
import com.yunbao.live.bean.ImUserBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.RecommendLiveRoomEvent;
|
import com.yunbao.live.event.RecommendLiveRoomEvent;
|
||||||
import com.yunbao.live.http.ImHttpUtil;
|
import com.yunbao.live.http.ImHttpUtil;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
|
@ -50,7 +50,7 @@ import com.yunbao.common.utils.DialogUitl;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
|
@ -24,7 +24,7 @@ import com.yunbao.common.manager.SearchHistoryRecordManager;
|
|||||||
import com.yunbao.common.utils.Bus;
|
import com.yunbao.common.utils.Bus;
|
||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.event.JumpUserHomeEvent;
|
import com.yunbao.main.event.JumpUserHomeEvent;
|
||||||
|
@ -8,7 +8,7 @@ import android.net.Uri;
|
|||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
import android.provider.MediaStore;
|
import android.provider.MediaStore;
|
||||||
import androidx.annotation.RequiresApi;
|
import androidx.annotation.RequiresApi;
|
||||||
import androidx.appcompat.app.AppCompatActivity;
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@ -35,7 +35,7 @@ import com.yunbao.common.utils.ToastUtil;
|
|||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.WebViewActivityMedal;
|
import com.yunbao.live.activity.WebViewActivityMedal;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.dialog.LiveUserDialogFragment;
|
import com.yunbao.live.dialog.LiveUserDialogFragment;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
|
@ -13,7 +13,7 @@ import com.yunbao.common.Constants;
|
|||||||
import com.yunbao.common.adapter.RefreshAdapter;
|
import com.yunbao.common.adapter.RefreshAdapter;
|
||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.utils.MainIconUtil;
|
import com.yunbao.main.utils.MainIconUtil;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -29,7 +29,7 @@ import com.yunbao.common.bean.WeekListBean;
|
|||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.common.utils.DpUtil;
|
import com.yunbao.common.utils.DpUtil;
|
||||||
import com.yunbao.common.utils.SVGAViewUtils;
|
import com.yunbao.common.utils.SVGAViewUtils;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.views.MainHomeLiveItemViewHolder;
|
import com.yunbao.main.views.MainHomeLiveItemViewHolder;
|
||||||
import com.yunbao.main.views.MainHomeLiveWeekItemViewHolder;
|
import com.yunbao.main.views.MainHomeLiveWeekItemViewHolder;
|
||||||
|
@ -20,7 +20,7 @@ import com.yunbao.common.adapter.RefreshAdapter;
|
|||||||
import com.yunbao.common.custom.RatioRoundImageView;
|
import com.yunbao.common.custom.RatioRoundImageView;
|
||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.common.utils.formatBigNum;
|
import com.yunbao.common.utils.formatBigNum;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.utils.MainIconUtil;
|
import com.yunbao.main.utils.MainIconUtil;
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ import android.widget.TextView;
|
|||||||
|
|
||||||
import com.yunbao.common.adapter.RefreshAdapter;
|
import com.yunbao.common.adapter.RefreshAdapter;
|
||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.utils.MainIconUtil;
|
import com.yunbao.main.utils.MainIconUtil;
|
||||||
|
|
||||||
|
@ -22,7 +22,7 @@ import com.yunbao.common.utils.CommonIconUtil;
|
|||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.SearchUserBean;
|
import com.yunbao.live.bean.SearchUserBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
|
@ -26,11 +26,10 @@ import com.yunbao.common.manager.NoviceInstructorManager;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.activity.EntryActivity;
|
|
||||||
import com.yunbao.main.activity.MainActivity;
|
import com.yunbao.main.activity.MainActivity;
|
||||||
|
|
||||||
import static com.yunbao.common.CommonAppContext.home_zdy_img_cn;
|
import static com.yunbao.common.CommonAppContext.home_zdy_img_cn;
|
||||||
|
@ -14,7 +14,7 @@ import com.yunbao.common.utils.MD5Util;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.http.LiveHttpConsts;
|
import com.yunbao.live.http.LiveHttpConsts;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
|
@ -4,7 +4,7 @@ import android.content.Context;
|
|||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
import com.yunbao.common.views.AbsMainViewHolder;
|
import com.yunbao.common.views.AbsMainViewHolder;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.activity.MainActivity;
|
import com.yunbao.main.activity.MainActivity;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -4,7 +4,6 @@ import android.content.ClipData;
|
|||||||
import android.content.ClipboardManager;
|
import android.content.ClipboardManager;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.graphics.drawable.AnimationDrawable;
|
|
||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
import android.os.Handler;
|
import android.os.Handler;
|
||||||
@ -23,7 +22,6 @@ import android.webkit.WebChromeClient;
|
|||||||
import android.webkit.WebSettings;
|
import android.webkit.WebSettings;
|
||||||
import android.webkit.WebView;
|
import android.webkit.WebView;
|
||||||
import android.webkit.WebViewClient;
|
import android.webkit.WebViewClient;
|
||||||
import android.widget.ImageView;
|
|
||||||
import android.widget.LinearLayout;
|
import android.widget.LinearLayout;
|
||||||
import android.widget.ProgressBar;
|
import android.widget.ProgressBar;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
@ -44,8 +42,7 @@ import com.yunbao.common.utils.ToastUtil;
|
|||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.LiveReportActivity;
|
import com.yunbao.live.activity.LiveReportActivity;
|
||||||
import com.yunbao.live.activity.SystemMessageActivity;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
|
||||||
import com.yunbao.live.bean.ReportCommunityBean;
|
import com.yunbao.live.bean.ReportCommunityBean;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
@ -55,7 +52,6 @@ import com.yunbao.main.activity.FansActivity;
|
|||||||
import com.yunbao.main.activity.MainActivity;
|
import com.yunbao.main.activity.MainActivity;
|
||||||
import com.yunbao.main.dialog.EncourageDialog;
|
import com.yunbao.main.dialog.EncourageDialog;
|
||||||
import com.yunbao.main.event.MainHomeCommunityToChatEvent;
|
import com.yunbao.main.event.MainHomeCommunityToChatEvent;
|
||||||
import com.yunbao.main.manager.imrongcloud.ConversationIMListManager;
|
|
||||||
import com.yunbao.main.utils.BottomBarUtil;
|
import com.yunbao.main.utils.BottomBarUtil;
|
||||||
import com.yunbao.video.activity.VideoPlayActivity;
|
import com.yunbao.video.activity.VideoPlayActivity;
|
||||||
import com.yunbao.video.bean.VideoBean;
|
import com.yunbao.video.bean.VideoBean;
|
||||||
|
@ -25,7 +25,7 @@ import com.yunbao.common.interfaces.OnItemClickListener;
|
|||||||
import com.yunbao.common.utils.DpUtil;
|
import com.yunbao.common.utils.DpUtil;
|
||||||
import com.yunbao.common.utils.L;
|
import com.yunbao.common.utils.L;
|
||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
|
|
||||||
import static android.content.Context.CLIPBOARD_SERVICE;
|
import static android.content.Context.CLIPBOARD_SERVICE;
|
||||||
|
@ -16,7 +16,7 @@ import com.yunbao.common.custom.ItemDecoration;
|
|||||||
import com.yunbao.common.http.HttpCallback;
|
import com.yunbao.common.http.HttpCallback;
|
||||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.activity.MainActivity;
|
import com.yunbao.main.activity.MainActivity;
|
||||||
import com.yunbao.main.activity.WeekWebViewActivity;
|
import com.yunbao.main.activity.WeekWebViewActivity;
|
||||||
|
@ -14,7 +14,7 @@ import com.yunbao.common.custom.ItemDecoration;
|
|||||||
import com.yunbao.common.http.HttpCallback;
|
import com.yunbao.common.http.HttpCallback;
|
||||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.utils.LiveStorge;
|
import com.yunbao.live.utils.LiveStorge;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.adapter.MainHomeFollowAdapter;
|
import com.yunbao.main.adapter.MainHomeFollowAdapter;
|
||||||
|
@ -16,7 +16,7 @@ import com.yunbao.common.custom.RatioRoundImageView;
|
|||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.common.utils.DpUtil;
|
import com.yunbao.common.utils.DpUtil;
|
||||||
import com.yunbao.common.utils.formatBigNum;
|
import com.yunbao.common.utils.formatBigNum;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.utils.MainIconUtil;
|
import com.yunbao.main.utils.MainIconUtil;
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ import com.yunbao.common.utils.RouteUtil;
|
|||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.common.views.CustomViewHolder;
|
import com.yunbao.common.views.CustomViewHolder;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
import com.yunbao.live.http.LiveHttpUtil;
|
import com.yunbao.live.http.LiveHttpUtil;
|
||||||
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
import com.yunbao.live.presenter.LiveRoomCheckLivePresenter;
|
||||||
|
@ -19,7 +19,7 @@ import com.opensource.svgaplayer.SVGAVideoEntity;
|
|||||||
import com.yunbao.common.bean.WeekListBean;
|
import com.yunbao.common.bean.WeekListBean;
|
||||||
import com.yunbao.common.glide.ImgLoader;
|
import com.yunbao.common.glide.ImgLoader;
|
||||||
import com.yunbao.common.utils.SVGAViewUtils;
|
import com.yunbao.common.utils.SVGAViewUtils;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -16,7 +16,7 @@ import com.yunbao.common.custom.ItemDecoration;
|
|||||||
import com.yunbao.common.http.HttpCallback;
|
import com.yunbao.common.http.HttpCallback;
|
||||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||||
import com.yunbao.common.utils.RouteUtil;
|
import com.yunbao.common.utils.RouteUtil;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.activity.MainActivity;
|
import com.yunbao.main.activity.MainActivity;
|
||||||
import com.yunbao.main.activity.WeekWebViewActivity;
|
import com.yunbao.main.activity.WeekWebViewActivity;
|
||||||
|
@ -22,7 +22,7 @@ import com.yunbao.common.interfaces.OnItemClickListener;
|
|||||||
import com.yunbao.common.utils.DpUtil;
|
import com.yunbao.common.utils.DpUtil;
|
||||||
import com.yunbao.common.utils.L;
|
import com.yunbao.common.utils.L;
|
||||||
import com.yunbao.common.utils.ToastUtil;
|
import com.yunbao.common.utils.ToastUtil;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.utils.BottomBarUtil;
|
import com.yunbao.main.utils.BottomBarUtil;
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ import com.yunbao.common.custom.CommonRefreshView;
|
|||||||
import com.yunbao.common.custom.ItemDecoration;
|
import com.yunbao.common.custom.ItemDecoration;
|
||||||
import com.yunbao.common.http.HttpCallback;
|
import com.yunbao.common.http.HttpCallback;
|
||||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.utils.LiveStorge;
|
import com.yunbao.live.utils.LiveStorge;
|
||||||
import com.yunbao.main.R;
|
import com.yunbao.main.R;
|
||||||
import com.yunbao.main.adapter.MainNearNearAdapter;
|
import com.yunbao.main.adapter.MainNearNearAdapter;
|
||||||
|
@ -48,7 +48,7 @@ import com.yunbao.common.utils.ToastUtil;
|
|||||||
import com.yunbao.common.utils.WordUtil;
|
import com.yunbao.common.utils.WordUtil;
|
||||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||||
import com.yunbao.live.activity.LiveReportActivity;
|
import com.yunbao.live.activity.LiveReportActivity;
|
||||||
import com.yunbao.live.bean.LiveBean;
|
import com.yunbao.common.bean.LiveBean;
|
||||||
import com.yunbao.live.bean.SearchUserBean;
|
import com.yunbao.live.bean.SearchUserBean;
|
||||||
import com.yunbao.live.dialog.LiveShareDialogFragment;
|
import com.yunbao.live.dialog.LiveShareDialogFragment;
|
||||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||||
|
Loading…
Reference in New Issue
Block a user