|
|
@@ -18,6 +18,8 @@ import com.sheep.gamegroup.event.WebViewEvent;
|
|
|
import com.sheep.gamegroup.model.api.IWeb;
|
|
|
import com.sheep.gamegroup.model.entity.BaseMessage;
|
|
|
import com.sheep.gamegroup.model.entity.DialogConfig;
|
|
|
+import com.sheep.gamegroup.model.entity.GameListType;
|
|
|
+import com.sheep.gamegroup.model.entity.Release_task;
|
|
|
import com.sheep.gamegroup.model.entity.TaskEty;
|
|
|
import com.sheep.gamegroup.model.util.SheepSubscriber;
|
|
|
import com.sheep.gamegroup.module.find.activity.ActFind;
|
|
|
@@ -29,9 +31,11 @@ import com.sheep.gamegroup.util.ApiJSONUtil;
|
|
|
import com.sheep.gamegroup.util.ApiUtil;
|
|
|
import com.sheep.gamegroup.util.CommonUtil;
|
|
|
import com.sheep.gamegroup.util.ContactUtil;
|
|
|
+import com.sheep.gamegroup.util.DataKey;
|
|
|
import com.sheep.gamegroup.util.DataUtil;
|
|
|
import com.sheep.gamegroup.util.DeviceUtil;
|
|
|
import com.sheep.gamegroup.util.Jump2View;
|
|
|
+import com.sheep.gamegroup.util.ListUtil;
|
|
|
import com.sheep.gamegroup.util.LogUtil;
|
|
|
import com.sheep.gamegroup.util.MainTab;
|
|
|
import com.sheep.gamegroup.util.QQUtil;
|
|
|
@@ -45,6 +49,7 @@ import com.sheep.gamegroup.view.activity.ChangeWxOrTelAct;
|
|
|
import com.sheep.gamegroup.view.activity.RealNameAuthenAct;
|
|
|
import com.sheep.jiuyan.samllsheep.R;
|
|
|
import com.sheep.jiuyan.samllsheep.SheepApp;
|
|
|
+import com.sheep.jiuyan.samllsheep.bean.UserCenterModule;
|
|
|
import com.sheep.jiuyan.samllsheep.utils.G;
|
|
|
import com.sheep.jiuyan.samllsheep.utils.PackageUtil;
|
|
|
import com.sheep.jiuyan.samllsheep.utils.SpUtils;
|
|
|
@@ -305,6 +310,22 @@ public class KFZSJs {
|
|
|
}
|
|
|
|
|
|
@JavascriptInterface
|
|
|
+ public void gotoTask(final int type, final int id) {
|
|
|
+ activity.runOnUiThread(() -> {
|
|
|
+ Release_task rt = new Release_task();
|
|
|
+ rt.setId(id);
|
|
|
+ rt.setTask(new TaskEty());
|
|
|
+ rt.getTask().setTask_type(type);
|
|
|
+ Jump2View.getInstance().goEntity(rt);
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ @JavascriptInterface
|
|
|
+ public void goTryplayView() {
|
|
|
+ Jump2View.getInstance().goTryplayView(activity, null);
|
|
|
+ }
|
|
|
+
|
|
|
+ @JavascriptInterface
|
|
|
public void setH5Type(final String h5Type) {
|
|
|
if (h5Type == null)
|
|
|
return;
|
|
|
@@ -503,6 +524,22 @@ public class KFZSJs {
|
|
|
}
|
|
|
|
|
|
@JavascriptInterface
|
|
|
+ public void goActPlayGameList(int type) {
|
|
|
+ GameListType gameListType = new GameListType();
|
|
|
+ gameListType.setPort_type(type);
|
|
|
+ gameListType.setTitle("");
|
|
|
+ Jump2View.getInstance().goActPlayGameList(activity, gameListType);
|
|
|
+ }
|
|
|
+
|
|
|
+ @JavascriptInterface
|
|
|
+ public void goZoneGameList(int id, String name) {
|
|
|
+ GameListType type = new GameListType();
|
|
|
+ type.setSpecial_id(id);
|
|
|
+ type.setTitle(name);
|
|
|
+ Jump2View.getInstance().goActPlayGameList(activity, type);
|
|
|
+ }
|
|
|
+
|
|
|
+ @JavascriptInterface
|
|
|
public void gotoGameGroupDetail(int id) {
|
|
|
Jump2View.getInstance().goActGameGroupDetail(id);
|
|
|
}
|
|
|
@@ -546,6 +583,19 @@ public class KFZSJs {
|
|
|
});
|
|
|
}
|
|
|
|
|
|
-// @JavascriptInterface
|
|
|
-// public void put
|
|
|
+ @JavascriptInterface
|
|
|
+ public void putIntData(String key, int value) {
|
|
|
+ DataUtil.putAsInt(key, value);
|
|
|
+ }
|
|
|
+
|
|
|
+ @JavascriptInterface
|
|
|
+ public int getIntData(String key, int def) {
|
|
|
+ return DataUtil.getAsInt(key, 1);
|
|
|
+ }
|
|
|
+
|
|
|
+ @JavascriptInterface
|
|
|
+ public void goNativeFromUser(String jsonStr) {
|
|
|
+ UserCenterModule module = JSONObject.parseObject(jsonStr, UserCenterModule.class);
|
|
|
+ CommonUtil.getInstance().goNative(activity, module, "个人中心");
|
|
|
+ }
|
|
|
}
|