add:新增活动中心入口
update:LiveHDDialogFragment新增全屏入参构造方法
This commit is contained in:
parent
801d9f3e54
commit
7bbe82d72c
@ -126,6 +126,7 @@
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/activity_center"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="28dp"
|
||||
|
@ -819,6 +819,17 @@ public class LiveAudienceActivity extends LiveActivity {
|
||||
mLiveGuardInfo = event.getParametersModel().getmLiveGuardInfo() == null ?
|
||||
mLiveGuardInfo : event.getParametersModel().getmLiveGuardInfo();
|
||||
break;
|
||||
case ACTIVITY_CENTER://活动中心
|
||||
String url = CommonAppConfig.HOST + "/h5/live/hallOfFame/index.html?g=Appapi&m=Turntable&a=tricky";
|
||||
url += "&uid=" + CommonAppConfig.getInstance().getUid() + "&token="
|
||||
+ CommonAppConfig.getInstance().getToken() + "&anchorUid=" + mLiveUid;
|
||||
Log.i("tag", url);
|
||||
Bundle bundle1 = new Bundle();
|
||||
bundle1.putString("url", url);
|
||||
liveHDDialogFragment = new LiveHDDialogFragment(true);
|
||||
liveHDDialogFragment.setArguments(bundle1);
|
||||
liveHDDialogFragment.show(((LiveAudienceActivity) mContext).getSupportFragmentManager(), "LiveHDDialogFragment");
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
|
@ -37,6 +37,19 @@ public class LiveHDDialogFragment extends AbsDialogFragment {
|
||||
|
||||
private WebView mWebView;
|
||||
private int showType = 0;
|
||||
private boolean isFullWindow=false;
|
||||
|
||||
public LiveHDDialogFragment() {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 弹出全屏对话框
|
||||
* @param isFullWindow 是否为全屏模式
|
||||
*/
|
||||
public LiveHDDialogFragment(boolean isFullWindow) {
|
||||
this.isFullWindow = isFullWindow;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getLayoutId() {
|
||||
@ -59,7 +72,11 @@ public class LiveHDDialogFragment extends AbsDialogFragment {
|
||||
window.setWindowAnimations(R.style.bottomToTopAnim);
|
||||
WindowManager.LayoutParams params = window.getAttributes();
|
||||
params.width = WindowManager.LayoutParams.MATCH_PARENT;
|
||||
params.height = WindowManager.LayoutParams.WRAP_CONTENT;
|
||||
if(isFullWindow){
|
||||
params.height = WindowManager.LayoutParams.MATCH_PARENT;
|
||||
}else {
|
||||
params.height = WindowManager.LayoutParams.WRAP_CONTENT;
|
||||
}
|
||||
params.gravity = Gravity.BOTTOM;
|
||||
window.setAttributes(params);
|
||||
}
|
||||
|
@ -109,6 +109,12 @@ public class LiveTotalDialog extends AbsDialogFragment {
|
||||
dismiss();
|
||||
}
|
||||
);
|
||||
//活动中心
|
||||
ViewClicksAntiShake.clicksAntiShake(findViewById(R.id.activity_center),()->{
|
||||
Bus.get().post(new LiveAudienceEvent()
|
||||
.setType(LiveAudienceEvent.LiveAudienceType.ACTIVITY_CENTER));
|
||||
dismiss();
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -58,8 +58,8 @@ public class LiveAudienceEvent extends BaseModel {
|
||||
LIAN_MAI(9, "连麦"),
|
||||
EFFECTS_SETTINGS(10, "特效設置"),
|
||||
WISH_LIST(11, "心愿单"),
|
||||
OPEN_PARAMETERS(12, "开放参数");
|
||||
|
||||
OPEN_PARAMETERS(12, "开放参数"),
|
||||
ACTIVITY_CENTER(13, "活動中心");
|
||||
|
||||
private int type;
|
||||
private String name;
|
||||
|
Loading…
Reference in New Issue
Block a user