添加贵族,连麦
This commit is contained in:
parent
31de4dc516
commit
d3a3569f2b
@ -83,6 +83,20 @@ public class LiveTotalDialog extends AbsDialogFragment {
|
||||
dismiss();
|
||||
}
|
||||
);
|
||||
//贵族
|
||||
ViewClicksAntiShake.clicksAntiShake(findViewById(R.id.noble_layout), () -> {
|
||||
Bus.get().post(new LiveAudienceEvent()
|
||||
.setType(LiveAudienceEvent.LiveAudienceType.NOBLE));
|
||||
dismiss();
|
||||
}
|
||||
);
|
||||
//连麦
|
||||
ViewClicksAntiShake.clicksAntiShake(findViewById(R.id.live_link_mic), () -> {
|
||||
Bus.get().post(new LiveAudienceEvent()
|
||||
.setType(LiveAudienceEvent.LiveAudienceType.LIANMAI));
|
||||
dismiss();
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -32,7 +32,9 @@ public class LiveAudienceEvent extends BaseModel {
|
||||
CURRENTACTIVITY(4, "当前活动"),
|
||||
FANCLUB(5, "粉絲團"),
|
||||
GUARD(6, "守護"),
|
||||
LIVEWKS(7,"周星榜");
|
||||
LIVEWKS(7, "周星榜"),
|
||||
NOBLE(8, "贵族"),
|
||||
LIANMAI(9, "连麦");
|
||||
|
||||
|
||||
private int type;
|
||||
|
@ -148,4 +148,9 @@ public interface PDLiveApi {
|
||||
*/
|
||||
@GET("/api/public/?service=Active.getActiveList")
|
||||
Observable<ResponseModel<List<ActiveModel>>> getActiveList();
|
||||
/**
|
||||
* 获取活动
|
||||
*/
|
||||
@GET("/api/public/?service=live.getDrLm")
|
||||
Observable<ResponseModel<List<ActiveModel>>> getDrLm();
|
||||
}
|
||||
|
@ -82,6 +82,7 @@
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/noble_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="28dp"
|
||||
@ -164,6 +165,7 @@
|
||||
android:layout_marginBottom="20dp">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/live_link_mic"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
|
@ -84,6 +84,7 @@ import com.yunbao.live.dialog.LiveFansFragment;
|
||||
import com.yunbao.live.dialog.LiveGiftDialogFragment;
|
||||
import com.yunbao.live.dialog.LiveGuardDialogFragment;
|
||||
import com.yunbao.live.dialog.LiveHDDialogFragment;
|
||||
import com.yunbao.live.dialog.LiveMicUserDialogFragment;
|
||||
import com.yunbao.live.dialog.NewUserDialog;
|
||||
import com.yunbao.live.event.LinkMicTxAccEvent;
|
||||
import com.yunbao.live.event.LiveRoomChangeEvent;
|
||||
@ -1386,6 +1387,11 @@ public class LiveAudienceActivity extends LiveActivity {
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 跳转页面或者弹窗展示
|
||||
*
|
||||
* @param event
|
||||
*/
|
||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||
public void onOpenDrawer(LiveAudienceEvent event) {
|
||||
Bundle bundle = new Bundle();
|
||||
@ -1446,11 +1452,41 @@ public class LiveAudienceActivity extends LiveActivity {
|
||||
liveGuardDialogFragment.setArguments(bundle);
|
||||
liveGuardDialogFragment.show(getSupportFragmentManager(), "LiveGuardDialogFragment");
|
||||
break;
|
||||
case LIVEWKS:
|
||||
String url = CommonAppConfig.HOST + "/h5/activity/weekStar/index.html?&uid="
|
||||
case LIVEWKS://周星榜
|
||||
String weeklyStarUrl = CommonAppConfig.HOST + "/h5/activity/weekStar/index.html?&uid="
|
||||
+ userInfo.getId() +
|
||||
"&token=" + userInfo.getToken() + "&anchorUid=" + mLiveUid;
|
||||
ZhuangBanActivity.forward(mContext, url, false);
|
||||
ZhuangBanActivity.forward(mContext, weeklyStarUrl, false);
|
||||
break;
|
||||
case NOBLE:
|
||||
Constants.isTitle = true;
|
||||
String nobleUrl = CommonAppConfig.HOST + "/h5/Nobility.html?nickname=" + userInfo.getUserNicename()
|
||||
+ "&usernobId=" + userInfo.getNobleId()
|
||||
+ "&token=" + userInfo.getToken()
|
||||
+ "&uid=" + userInfo.getId();
|
||||
ZhuangBanActivity.forward(mContext, nobleUrl, false);
|
||||
break;
|
||||
case LIANMAI:
|
||||
//获取房间连麦状态
|
||||
HttpClient.getInstance().get("live.getDrLm", "live.getDrLm")
|
||||
.params("uid", mLiveUid, true)
|
||||
.execute(new HttpCallback() {
|
||||
@Override
|
||||
public void onSuccess(int code, String msg, String[] info) {
|
||||
if (code == 0) {
|
||||
LiveMicUserDialogFragment fragment = new LiveMicUserDialogFragment();
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putString(Constants.LIVE_UID, mLiveUid);
|
||||
bundle.putString(Constants.STREAM, mStream);
|
||||
bundle.putString("By", "1");
|
||||
fragment.setArguments(bundle);
|
||||
fragment.show(((LiveAudienceActivity) mContext).getSupportFragmentManager(), "LiveUserMoreDialogFragment");
|
||||
LiveMicUserDialogFragment.activity = ((LiveAudienceActivity) mContext);
|
||||
} else {
|
||||
ToastUtil.show(R.string.no_mic_opn);
|
||||
}
|
||||
}
|
||||
});
|
||||
break;
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user