补充信箱角标点亮和防抖
This commit is contained in:
parent
4729f93515
commit
1e4b0bb536
@ -4,8 +4,10 @@ import static com.yunbao.common.utils.RouteUtil.PATH_COIN;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
import android.content.DialogInterface;
|
||||
import android.text.Html;
|
||||
import android.text.Spanned;
|
||||
import android.view.View;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
@ -21,6 +23,7 @@ import com.yunbao.common.dialog.AbsDialogPopupWindow;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
import com.yunbao.common.utils.DialogUitl;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.live.R;
|
||||
import com.yunbao.live.http.LiveHttpUtil;
|
||||
|
||||
@ -32,12 +35,14 @@ public class LiveContactDetailsSendGiftDialog extends AbsDialogPopupWindow {
|
||||
TextView giftName;
|
||||
TextView diamond;
|
||||
ImageView giftIcon;
|
||||
View send;
|
||||
|
||||
int giftId;
|
||||
String anchorName;
|
||||
private String mLiveUid;
|
||||
private String mStream;
|
||||
LiveGiftBean bean;
|
||||
DialogInterface.OnDismissListener onDismissListener;
|
||||
|
||||
public LiveContactDetailsSendGiftDialog(@NonNull Context context) {
|
||||
super(context);
|
||||
@ -63,6 +68,11 @@ public class LiveContactDetailsSendGiftDialog extends AbsDialogPopupWindow {
|
||||
return this;
|
||||
}
|
||||
|
||||
public LiveContactDetailsSendGiftDialog setOnDismissListener(DialogInterface.OnDismissListener onDismissListener) {
|
||||
this.onDismissListener = onDismissListener;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void buildDialog(XPopup.Builder builder) {
|
||||
|
||||
@ -77,7 +87,8 @@ public class LiveContactDetailsSendGiftDialog extends AbsDialogPopupWindow {
|
||||
protected void onCreate() {
|
||||
super.onCreate();
|
||||
findViewById(R.id.back).setOnClickListener(v -> dismiss());
|
||||
findViewById(R.id.send).setOnClickListener(v -> send());
|
||||
send = findViewById(R.id.send);
|
||||
ViewClicksAntiShake.clicksAntiShake(send, this::send);
|
||||
|
||||
title = findViewById(R.id.title);
|
||||
giftIcon = findViewById(R.id.gift_icon);
|
||||
@ -113,6 +124,13 @@ public class LiveContactDetailsSendGiftDialog extends AbsDialogPopupWindow {
|
||||
}
|
||||
});
|
||||
}
|
||||
@Override
|
||||
protected void onDismiss() {
|
||||
super.onDismiss();
|
||||
if (onDismissListener != null) {
|
||||
onDismissListener.onDismiss(null);
|
||||
}
|
||||
}
|
||||
|
||||
private void setData(LiveGiftBean bean) {
|
||||
this.bean = bean;
|
||||
@ -149,6 +167,11 @@ public class LiveContactDetailsSendGiftDialog extends AbsDialogPopupWindow {
|
||||
dismiss();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError() {
|
||||
super.onError();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -5079,6 +5079,9 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
||||
.setAnchorName(mAnchorName)
|
||||
.setStream(mStream)
|
||||
.setLiveUid(mLiveUid)
|
||||
.setOnDismissListener(dialog1 -> {
|
||||
checkNewLetter();
|
||||
})
|
||||
.showDialog();
|
||||
loading.dismiss();
|
||||
}
|
||||
@ -5153,6 +5156,9 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
||||
.setAnchorName(mAnchorName)
|
||||
.setStream(mStream)
|
||||
.setLiveUid(mLiveUid)
|
||||
.setOnDismissListener(dialog1 -> {
|
||||
checkNewLetter();
|
||||
})
|
||||
.showDialog();
|
||||
loading.dismiss();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user