添加短剧签到
This commit is contained in:
parent
0d7bdce4f0
commit
f626ab03d4
@ -0,0 +1,32 @@
|
||||
package com.yunbao.common.dialog;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import com.lxj.xpopup.core.CenterPopupView;
|
||||
import com.yunbao.common.R;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
|
||||
public class SkitCheckInWasSuccessfulPopup extends CenterPopupView {
|
||||
public SkitCheckInWasSuccessfulPopup(@NonNull Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getImplLayoutId() {
|
||||
return R.layout.skit_check_in_was_successful_popup;
|
||||
}
|
||||
|
||||
// 执行初始化操作,比如:findView,设置点击,或者任何你弹窗内的业务逻辑
|
||||
@Override
|
||||
protected void onCreate() {
|
||||
super.onCreate();
|
||||
ViewClicksAntiShake.clicksAntiShake(findViewById(R.id.icon_slice_368), new ViewClicksAntiShake.ViewClicksCallBack() {
|
||||
@Override
|
||||
public void onViewClicks() {
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="258dp"
|
||||
android:layout_height="293dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:src="@mipmap/back_slice_367" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/icon_slice_368"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_gravity="end"
|
||||
android:layout_marginTop="89dp"
|
||||
android:layout_marginEnd="13dp"
|
||||
android:src="@mipmap/icon_slice_368" />
|
||||
|
||||
</FrameLayout>
|
BIN
common/src/main/res/mipmap-xxhdpi/back_slice_367.png
Normal file
BIN
common/src/main/res/mipmap-xxhdpi/back_slice_367.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 536 KiB |
BIN
common/src/main/res/mipmap-xxhdpi/icon_slice_368.png
Normal file
BIN
common/src/main/res/mipmap-xxhdpi/icon_slice_368.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.0 KiB |
@ -225,20 +225,20 @@ public class LiveBuyGuardDialog extends AbsDialogPopupWindow {
|
||||
MobclickAgent.onEvent(mContext, "star_guardian_people", "星之守护页面观看次数及人数");
|
||||
bottomPanel.setBackgroundResource(R.drawable.bg_star_guard_bottom_panel);
|
||||
ImgLoader.display(getContext(), R.mipmap.btn_star_guard, btnGuard);
|
||||
openTheGuard.setText(dataTipModel.isOpen() ? WordUtil.getNewString(R.string.renewal_guardian)
|
||||
openTheGuard.setText(dataTipModel.isOpen() ? WordUtil.isNewZh()?"續費星之守護":"Renew Star Guardian"
|
||||
: WordUtil.getNewString(R.string.open_the_start_guard));
|
||||
|
||||
} else if (position == 1) {
|
||||
MobclickAgent.onEvent(mContext, "king_guardian_people", "王之守护页面观看次数及人数");
|
||||
bottomPanel.setBackgroundResource(R.drawable.bg_king_guard_bottom_panel);
|
||||
ImgLoader.display(getContext(), R.mipmap.btn_king_guard, btnGuard);
|
||||
openTheGuard.setText(dataTipModel.isOpen() ? WordUtil.getNewString(R.string.renewal_guardian)
|
||||
openTheGuard.setText(dataTipModel.isOpen() ? WordUtil.isNewZh()?"續費王之守護":"Renew King Guardian"
|
||||
: WordUtil.getNewString(R.string.open_the_kings_guard));
|
||||
} else if (position == 2) {
|
||||
MobclickAgent.onEvent(mContext, "god_guardian_people", "神之守护页面观看次数及人数");
|
||||
bottomPanel.setBackgroundResource(R.drawable.bg_god_guard_bottom_panel);
|
||||
ImgLoader.display(getContext(), R.mipmap.btn_god_guard, btnGuard);
|
||||
openTheGuard.setText(dataTipModel.isOpen() ? WordUtil.getNewString(R.string.renewal_guardian)
|
||||
openTheGuard.setText(dataTipModel.isOpen() ? WordUtil.isNewZh()?"續費神之守護":"Renew God Guardian"
|
||||
: WordUtil.getNewString(R.string.open_the_god_guard));
|
||||
}
|
||||
guardPriceModel = price.get(0);
|
||||
@ -385,6 +385,7 @@ public class LiveBuyGuardDialog extends AbsDialogPopupWindow {
|
||||
dismiss();
|
||||
if (dataTipModel.getGuardType() == 3) {
|
||||
new XPopup.Builder(mContext)
|
||||
.dismissOnTouchOutside(false) // 点击外部是否关闭弹窗,默认为true
|
||||
.asCustom(new DragonSendsMoneyPopup(mContext, mLiveUid))
|
||||
.show();
|
||||
}
|
||||
|
@ -204,37 +204,37 @@ public class LiveGuardDialog extends AbsDialogPopupWindow {
|
||||
guardianTask.setVisibility(GONE);
|
||||
myGraudGrade.setVisibility(GONE);
|
||||
btnGuardOpen.setText(WordUtil.isNewZh() ? "開通守護" : "Open Guard");
|
||||
guard_hint.setText(WordUtil.isNewZh()?"快為您喜歡的主播開通守護吧!":"Turn on the guard for your favorite anchor!");
|
||||
guard_hint.setText(WordUtil.isNewZh() ? "快為您喜歡的主播開通守護吧!" : "Turn on the guard for your favorite anchor!");
|
||||
} else {
|
||||
if (data.getGuardType() == 0) {
|
||||
guardianTask.setVisibility(GONE);
|
||||
myGraudGrade.setVisibility(GONE);
|
||||
btnGuardOpen.setText(WordUtil.isNewZh() ? "開通守護" : "Open Guard");
|
||||
guard_hint.setText(WordUtil.isNewZh()?"快為您喜歡的主播開通守護吧!":"Turn on the guard for your favorite anchor!");
|
||||
guard_hint.setText(WordUtil.isNewZh() ? "快為您喜歡的主播開通守護吧!" : "Turn on the guard for your favorite anchor!");
|
||||
} else {
|
||||
guardianTask.setVisibility(VISIBLE);
|
||||
myGraudGrade.setVisibility(VISIBLE);
|
||||
btnGuardOpen.setText(WordUtil.isNewZh() ? "續費守護" : "Renewal Guard");
|
||||
btnGuardOpen.setText(WordUtil.isNewZh() ? "續費守護" : "Renewal");
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "您是當前主播的" : "You are the ");
|
||||
switch (data.getGuardType()) {
|
||||
case 1:
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "星之守護" : "star guardian")
|
||||
.append(" of the current streamer");
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "【星之守護】" : "【star guardian】")
|
||||
.append(WordUtil.isNewZh() ? " " :" of the current streamer");
|
||||
guard_hint.setText(stringBuffer.toString());
|
||||
break;
|
||||
case 2:
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "王之守護" : "king guardian")
|
||||
.append(" of the current streamer");
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "【王之守護】" : "【king guardian】")
|
||||
.append(WordUtil.isNewZh() ? " " :" of the current streamer");
|
||||
guard_hint.setText(stringBuffer.toString());
|
||||
break;
|
||||
case 3:
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "神之守護" : "god guardian")
|
||||
.append(" of the current streamer");
|
||||
stringBuffer.append(WordUtil.isNewZh() ? "【神之守護】" : "【god guardian】")
|
||||
.append(WordUtil.isNewZh() ? " " :" of the current streamer");
|
||||
guard_hint.setText(stringBuffer.toString());
|
||||
break;
|
||||
default:
|
||||
guard_hint.setText(WordUtil.isNewZh()?"快為您喜歡的主播開通守護吧!":"Turn on the guard for your favorite anchor!");
|
||||
guard_hint.setText(WordUtil.isNewZh() ? "快為您喜歡的主播開通守護吧!" : "Turn on the guard for your favorite anchor!");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -33,6 +33,7 @@ import com.yunbao.common.Constants;
|
||||
import com.yunbao.common.bean.CoolConfig;
|
||||
import com.yunbao.common.bean.NativeCallbackModel;
|
||||
import com.yunbao.common.dialog.CinemaTicketPopupWindow;
|
||||
import com.yunbao.common.dialog.SkitCheckInWasSuccessfulPopup;
|
||||
import com.yunbao.common.event.JavascriptInterfaceEvent;
|
||||
import com.yunbao.common.fragment.BaseFragment;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
@ -226,6 +227,15 @@ public class MainHomeCommunityVideoFragment extends BaseFragment {
|
||||
System.out.println("code = " + code + ", msg = " + msg + ", info = " + Arrays.toString(info));
|
||||
if (code == 0) {
|
||||
mWebView.loadUrl(JSONObject.parseObject(info[0]).getString("url"));
|
||||
String sign_ok = JSONObject.parseObject(info[0]).getString("sign_ok");
|
||||
if (TextUtils.equals(sign_ok,"1")){
|
||||
new XPopup.Builder(mContext)
|
||||
.asCustom(new SkitCheckInWasSuccessfulPopup(mContext))
|
||||
.show();
|
||||
}
|
||||
// new XPopup.Builder(mContext)
|
||||
// .asCustom(new SkitCheckInWasSuccessfulPopup(mContext))
|
||||
// .show();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -6,8 +6,10 @@ import android.view.ViewGroup;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.ImageView;
|
||||
|
||||
import com.lxj.xpopup.XPopup;
|
||||
import com.umeng.analytics.MobclickAgent;
|
||||
import com.yunbao.common.activity.AbsActivity;
|
||||
import com.yunbao.common.dialog.SkitCheckInWasSuccessfulPopup;
|
||||
import com.yunbao.common.event.FloatWarOrderEvent;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.live.dialog.LiveBuyGuardDialog;
|
||||
@ -54,7 +56,9 @@ public class MainHomeViewHolder extends AbsMainHomeParentViewHolder {
|
||||
// img_trophy.setOnLongClickListener(new View.OnLongClickListener() {
|
||||
// @Override
|
||||
// public boolean onLongClick(View view) {
|
||||
//
|
||||
// new XPopup.Builder(mContext)
|
||||
// .asCustom(new SkitCheckInWasSuccessfulPopup(mContext))
|
||||
// .show();
|
||||
// return true;
|
||||
// }
|
||||
// });
|
||||
|
Loading…
Reference in New Issue
Block a user