[2.11.0] 1、bus到站接口请求容错处理 2、taxi乘客屏偶现崩溃处理

This commit is contained in:
wangmingjun
2022-10-20 14:18:38 +08:00
parent ba02f80f3d
commit 413ea46fab
3 changed files with 38 additions and 4 deletions

View File

@@ -4,6 +4,11 @@ import com.mogo.commons.debug.DebugConfig;
import com.mogo.eagle.core.utilcode.util.ToastUtils;
public class ToastUtilsOch {
private static long lastClickTime;
// 两次点击按钮之间的点击间隔不能少于1000毫秒
private static int MIN_CLICK_DELAY_TIME = 1000;
public static void showWithCodeMessage(int code,String message){
if(message==null){
return;
@@ -14,4 +19,15 @@ public class ToastUtilsOch {
ToastUtils.showShort(message);
}
}
public static boolean isCustomFastClick(int customCLickDelayTime) {
MIN_CLICK_DELAY_TIME = customCLickDelayTime;
boolean flag = false;
long curClickTime = System.currentTimeMillis();
if ((curClickTime - lastClickTime) >= MIN_CLICK_DELAY_TIME) {
flag = true;
}
lastClickTime = curClickTime;
return flag;
}
}