fix:修复小时榜点自己直播间会跳转的问题
This commit is contained in:
parent
4e466a7868
commit
2acba510f7
@ -47,6 +47,7 @@ public class LiveHDDialogFragment extends AbsDialogFragment {
|
||||
private WebView mWebView;
|
||||
private int showType = 0;
|
||||
private boolean isFullWindow=false;
|
||||
private String roomId;
|
||||
|
||||
public LiveHDDialogFragment() {
|
||||
|
||||
@ -145,6 +146,7 @@ public class LiveHDDialogFragment extends AbsDialogFragment {
|
||||
if (bundle == null) {
|
||||
return;
|
||||
}
|
||||
roomId=bundle.getString("roomId",null);
|
||||
mWebView.getSettings().setJavaScriptCanOpenWindowsAutomatically(true); // 是否允许JS打开新窗口
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
|
||||
mWebView.getSettings().setMixedContentMode(WebSettings.MIXED_CONTENT_ALWAYS_ALLOW);
|
||||
@ -248,6 +250,9 @@ public class LiveHDDialogFragment extends AbsDialogFragment {
|
||||
}
|
||||
private LiveRoomCheckLivePresenter mCheckLivePresenter;
|
||||
private void gotoLive(final String live_id) {
|
||||
if(roomId!=null&&roomId.equals(live_id)){
|
||||
return;
|
||||
}
|
||||
LiveHttpUtil.getLiveInfo(live_id, new HttpCallback() {
|
||||
@Override
|
||||
public void onSuccess(int code, String msg, String[] info) {
|
||||
|
@ -1120,6 +1120,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
||||
bundle.putString("url", url);
|
||||
bundle.putInt("height", DpUtil.dp2px(500));
|
||||
bundle.putInt("show_type", 0);
|
||||
bundle.putString("roomId",mLiveUid);
|
||||
LiveHDDialogFragment liveHDDialogFragment = new LiveHDDialogFragment();
|
||||
liveHDDialogFragment.setArguments(bundle);
|
||||
liveHDDialogFragment.show(((LiveAudienceActivity) mContext).getSupportFragmentManager(), "LiveHDDialogFragment");
|
||||
|
Loading…
Reference in New Issue
Block a user