测试修改
This commit is contained in:
@@ -42,7 +42,6 @@ import com.google.gson.Gson;
|
||||
import com.google.gson.reflect.TypeToken;
|
||||
import com.jakewharton.rxbinding3.view.RxView;
|
||||
import com.lzf.easyfloat.EasyFloat;
|
||||
import com.lzf.easyfloat.interfaces.OnPermissionResult;
|
||||
import com.lzf.easyfloat.permission.PermissionUtils;
|
||||
import com.tencent.imsdk.v2.V2TIMCallback;
|
||||
import com.tencent.imsdk.v2.V2TIMManager;
|
||||
@@ -91,7 +90,6 @@ import com.yunbao.common.utils.WordUtil;
|
||||
import com.yunbao.common.views.AbsMainViewHolder;
|
||||
import com.yunbao.common.views.floatingview.APPEasyFloat;
|
||||
import com.yunbao.common.views.weight.LiveFloatView;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.live.activity.LiveAudienceActivity;
|
||||
import com.yunbao.live.http.LiveHttpConsts;
|
||||
import com.yunbao.live.http.LiveHttpUtil;
|
||||
@@ -204,7 +202,7 @@ public class MainActivity extends AbsActivity implements MainAppBarLayoutListene
|
||||
CommonHttpUtil.getConfig(mContext, new CommonCallback<ConfigBean>() {
|
||||
@Override
|
||||
public void callback(ConfigBean bean) {
|
||||
if(bean==null){
|
||||
if (bean == null) {
|
||||
return;
|
||||
}
|
||||
//是否需要老用户回归弹窗
|
||||
@@ -630,25 +628,22 @@ 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;
|
||||
}
|
||||
int i = v.getId();
|
||||
if (i == R.id.btn_start) {
|
||||
showStartDialog();
|
||||
} else if (i == R.id.btn_search) {
|
||||
SearchActivity.forward(mContext);
|
||||
} else if (i == R.id.btn_follow) {
|
||||
//关注
|
||||
FollowActivity.forward(mContext, CommonAppConfig.getInstance().getUid(), 0);
|
||||
} else if (i == R.id.img_trophy) {
|
||||
MainListActivity.forward(mContext, 0);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
int i = v.getId();
|
||||
if (i == R.id.btn_start) {
|
||||
showStartDialog();
|
||||
} else if (i == R.id.btn_search) {
|
||||
SearchActivity.forward(mContext);
|
||||
} else if (i == R.id.btn_follow) {
|
||||
//关注
|
||||
FollowActivity.forward(mContext, CommonAppConfig.getInstance().getUid(), 0);
|
||||
} else if (i == R.id.img_trophy) {
|
||||
MainListActivity.forward(mContext, 0);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -731,7 +726,7 @@ public class MainActivity extends AbsActivity implements MainAppBarLayoutListene
|
||||
bundle.putString("send_exp", obj.getString("send_exp"));
|
||||
bundle.putString("sign_day", obj.getString("sign_day"));
|
||||
fragment.setArguments(bundle);
|
||||
if(!getSupportFragmentManager().isStateSaved()) {
|
||||
if (!getSupportFragmentManager().isStateSaved()) {
|
||||
fragment.show(getSupportFragmentManager(), "SigninDialog");
|
||||
}
|
||||
}
|
||||
@@ -938,6 +933,7 @@ public class MainActivity extends AbsActivity implements MainAppBarLayoutListene
|
||||
mMainHomeCommunityViewHolder.loadNewUrl();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
if (isTabClose && isWebClose) {
|
||||
|
||||
@@ -23,10 +23,9 @@ import com.yunbao.common.custom.MyRadioButton;
|
||||
import com.yunbao.common.glide.ImgLoader;
|
||||
import com.yunbao.common.http.CommonHttpUtil;
|
||||
import com.yunbao.common.utils.CommonIconUtil;
|
||||
import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.common.utils.SVGAViewUtils;
|
||||
import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.main.R;
|
||||
import com.yunbao.main.bean.ListBean;
|
||||
|
||||
@@ -69,51 +68,51 @@ 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) {
|
||||
ListBean model = (ListBean) tag;
|
||||
if (model.isHide()) {
|
||||
ToastUtil.show(R.string.can_not_go);
|
||||
} else {
|
||||
mOnItemClickListener.onItemClick(model, 0);
|
||||
}
|
||||
|
||||
Object tag = v.getTag();
|
||||
if (tag != null && mOnItemClickListener != null) {
|
||||
ListBean model = (ListBean) tag;
|
||||
if (model.isHide()) {
|
||||
ToastUtil.show(R.string.can_not_go);
|
||||
} else {
|
||||
mOnItemClickListener.onItemClick(model, 0);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
mFollowClickListener1 = new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
ViewClicksAntiShake.clicksAntiShake(v, () -> {
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
Object tag = v.getTag();
|
||||
if (tag != null) {
|
||||
final ListBean bean = (ListBean) tag;
|
||||
CommonHttpUtil.setAttention(bean.getUid(), null);
|
||||
}
|
||||
});
|
||||
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
Object tag = v.getTag();
|
||||
if (tag != null) {
|
||||
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;
|
||||
}
|
||||
Object tag = v.getTag();
|
||||
if (tag != null) {
|
||||
final int position = (int) tag;
|
||||
final ListBean bean = mList.get(position);
|
||||
CommonHttpUtil.setAttention(bean.getUid(), null);
|
||||
}
|
||||
});
|
||||
|
||||
if (!canClick()) {
|
||||
return;
|
||||
}
|
||||
Object tag = v.getTag();
|
||||
if (tag != null) {
|
||||
final int position = (int) tag;
|
||||
final ListBean bean = mList.get(position);
|
||||
CommonHttpUtil.setAttention(bean.getUid(), null);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
@@ -288,7 +287,7 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
public void onComplete(SVGAVideoEntity videoItem) {
|
||||
SVGADrawable drawable = new SVGADrawable(videoItem);
|
||||
svga1.setImageDrawable(drawable);
|
||||
SVGAViewUtils.playEndClear(svga1,false);
|
||||
SVGAViewUtils.playEndClear(svga1, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -365,7 +364,7 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
public void onComplete(SVGAVideoEntity videoItem) {
|
||||
SVGADrawable drawable = new SVGADrawable(videoItem);
|
||||
svga2.setImageDrawable(drawable);
|
||||
SVGAViewUtils.playEndClear(svga2,false);
|
||||
SVGAViewUtils.playEndClear(svga2, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -441,7 +440,7 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
public void onComplete(SVGAVideoEntity videoItem) {
|
||||
SVGADrawable drawable = new SVGADrawable(videoItem);
|
||||
svga3.setImageDrawable(drawable);
|
||||
SVGAViewUtils.playEndClear(svga3,false);
|
||||
SVGAViewUtils.playEndClear(svga3, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -544,7 +543,7 @@ public class MainListAdapter extends RefreshAdapter<ListBean> {
|
||||
public void onComplete(SVGAVideoEntity videoItem) {
|
||||
SVGADrawable drawable = new SVGADrawable(videoItem);
|
||||
svga.setImageDrawable(drawable);
|
||||
SVGAViewUtils.playEndClear(svga,false);
|
||||
SVGAViewUtils.playEndClear(svga, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -45,7 +45,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;
|
||||
@@ -54,7 +54,7 @@ public class SettingAdapter extends RecyclerView.Adapter {
|
||||
mOnItemClickListener.onItemClick(bean, position);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
@@ -452,7 +452,7 @@ 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));
|
||||
@@ -477,7 +477,7 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
String url = CommonAppConfig.HOST + "/h5/Noble/index.html?nickname=" + u.getUserNiceName() + "&usernobId=" + u.getNoble_id() + "&token=" + CommonAppConfig.getInstance().getToken() + "&uid=" + CommonAppConfig.getInstance().getUid();
|
||||
ZhuangBanActivity.forward(mContext, url, false);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user