防抖,主播私聊修复
This commit is contained in:
parent
892aaab6c0
commit
a453a526fa
@ -9,9 +9,9 @@ ext {
|
||||
]
|
||||
manifestPlaceholders = [
|
||||
//正式
|
||||
// serverHost : "https://napi.yaoulive.com",
|
||||
serverHost : "https://napi.yaoulive.com",
|
||||
//測試
|
||||
serverHost : "https://ceshi.yaoulive.com",
|
||||
// serverHost : "https://ceshi.yaoulive.com",
|
||||
|
||||
//腾讯地图
|
||||
txMapAppKey : "EOZBZ-ASLCU-4XPV3-BDCHZ-4E3Q7-H4BWB",
|
||||
|
@ -76,6 +76,7 @@ import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.common.utils.VersionUtil;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
import com.yunbao.common.views.AbsMainViewHolder;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||
import com.yunbao.live.bean.LiveBean;
|
||||
import com.yunbao.live.http.LiveHttpConsts;
|
||||
@ -557,6 +558,9 @@ public class MainActivity extends AbsActivity implements MainAppBarLayoutListene
|
||||
// });
|
||||
|
||||
public void mainClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, new ViewClicksAntiShake.ViewClicksCallBack() {
|
||||
@Override
|
||||
public void onViewClicks() {
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
@ -569,9 +573,12 @@ public class MainActivity extends AbsActivity implements MainAppBarLayoutListene
|
||||
//关注
|
||||
FollowActivity.forward(mContext, CommonAppConfig.getInstance().getUid(), 0);
|
||||
} else if (i == R.id.img_trophy) {
|
||||
MainListActivity.forward(this, 0);
|
||||
MainListActivity.forward(mContext, 0);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
private void showStartDialog() {
|
||||
if (isReady == true) {
|
||||
|
@ -2,8 +2,6 @@ package com.yunbao.main.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Color;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
@ -11,6 +9,9 @@ import android.view.ViewGroup;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.opensource.svgaplayer.SVGADrawable;
|
||||
import com.opensource.svgaplayer.SVGAImageView;
|
||||
import com.opensource.svgaplayer.SVGAParser;
|
||||
@ -23,6 +24,7 @@ import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.CommonHttpUtil;
|
||||
import com.yunbao.common.utils.CommonIconUtil;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.main.R;
|
||||
import com.yunbao.main.bean.ListBean;
|
||||
|
||||
@ -63,15 +65,19 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
mItemClickListener = new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, () -> {
|
||||
Object tag = v.getTag();
|
||||
if (tag != null && mOnItemClickListener != null) {
|
||||
mOnItemClickListener.onItemClick((ListBean) tag, 0);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
};
|
||||
mFollowClickListener1 = new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, () -> {
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
@ -80,11 +86,14 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
final ListBean bean = (ListBean) tag;
|
||||
CommonHttpUtil.setAttention(bean.getUid(), null);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
};
|
||||
mFollowClickListener2 = new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, () -> {
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
@ -94,6 +103,8 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
final ListBean bean = mList.get(position);
|
||||
CommonHttpUtil.setAttention(bean.getUid(), null);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -2,18 +2,20 @@ package com.yunbao.main.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Color;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.yunbao.common.Constants;
|
||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.main.BuildConfig;
|
||||
import com.yunbao.main.R;
|
||||
import com.yunbao.main.bean.SettingBean;
|
||||
import com.yunbao.common.interfaces.OnItemClickListener;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@ -42,6 +44,7 @@ public class SettingAdapter extends RecyclerView.Adapter {
|
||||
mOnClickListener = new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, () -> {
|
||||
Object tag = v.getTag();
|
||||
if (tag != null) {
|
||||
int position = (int) tag;
|
||||
@ -50,6 +53,8 @@ public class SettingAdapter extends RecyclerView.Adapter {
|
||||
mOnItemClickListener.onItemClick(bean, position);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@ -17,6 +17,7 @@ import com.yunbao.common.http.CommonHttpUtil;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
import com.yunbao.common.manager.InstructorRemarkManager;
|
||||
import com.yunbao.common.utils.RouteUtil;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.live.activity.PDLIiveChatActivity;
|
||||
import com.yunbao.live.activity.PDLiveConversationActivity;
|
||||
import com.yunbao.live.bean.SearchUserBean;
|
||||
@ -245,7 +246,7 @@ public class ConversationIMListManager {
|
||||
*/
|
||||
@Override
|
||||
public boolean onConversationClick(Context context, View view, BaseUiConversation baseUiConversation) {
|
||||
jumpConversation((Activity) context, baseUiConversation.mCore.getTargetId());
|
||||
ViewClicksAntiShake.clicksAntiShake(view, () -> jumpConversation((Activity) context, baseUiConversation.mCore.getTargetId()));
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
@ -451,20 +451,13 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, () -> {
|
||||
int i = v.getId();
|
||||
if (i == R.id.lt_name) {
|
||||
mContext.startActivity(new Intent(mContext, EditProfileActivity.class));
|
||||
} else if (i == R.id.signature) {
|
||||
mContext.startActivity(new Intent(mContext, EditProfileActivity.class));
|
||||
}
|
||||
// else if (i == R.id.btn_follow) {
|
||||
// forwardFollow();
|
||||
// }
|
||||
// else if (i == R.id.btn_fans) {
|
||||
// forwardFans();
|
||||
// } else if (i == R.id.btn_msg) {
|
||||
// ChatActivity.forward(mContext);
|
||||
// }
|
||||
else if (i == R.id.lt_star_coin) {
|
||||
mContext.startActivity(new Intent(mContext, MyWalletActivity.class).putExtra("p", 1));
|
||||
} else if (i == R.id.btn_coin) {
|
||||
@ -483,6 +476,8 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
String url = CommonAppConfig.HOST + "/h5/Nobility.html?nickname=" + u.getUserNiceName() + "&usernobId=" + u.getNoble_id() + "&token=" + CommonAppConfig.getInstance().getToken() + "&uid=" + CommonAppConfig.getInstance().getUid();
|
||||
ZhuangBanActivity.forward(mContext, url, false);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user