From 1c91b62ea573082581e72fd433d02e3dc52dbf51 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期一, 05 一月 2026 11:03:29 +0800
Subject: [PATCH] 2026年01月05日11:00:26 升级gradle和uni库
---
app/src/main/java/com/hdl/photovoltaic/ui/StartActivity.java | 47 ++++++++++++++++++++---------------------------
1 files changed, 20 insertions(+), 27 deletions(-)
diff --git a/app/src/main/java/com/hdl/photovoltaic/ui/StartActivity.java b/app/src/main/java/com/hdl/photovoltaic/ui/StartActivity.java
index f8667dd..680539e 100644
--- a/app/src/main/java/com/hdl/photovoltaic/ui/StartActivity.java
+++ b/app/src/main/java/com/hdl/photovoltaic/ui/StartActivity.java
@@ -14,6 +14,7 @@
import androidx.annotation.NonNull;
+import com.alibaba.fastjson.JSONObject;
import com.hdl.linkpm.sdk.core.exception.HDLException;
import com.hdl.linkpm.sdk.user.HDLLinkPMUser;
import com.hdl.photovoltaic.HDLApp;
@@ -21,7 +22,9 @@
import com.hdl.photovoltaic.base.CustomBaseActivity;
import com.hdl.photovoltaic.config.AppConfigManage;
import com.hdl.photovoltaic.config.UserConfigManage;
+import com.hdl.photovoltaic.enums.Languages;
import com.hdl.photovoltaic.listener.CloudCallBeak;
+import com.hdl.photovoltaic.other.HdlCommonLogic;
import com.hdl.photovoltaic.other.HdlResidenceLogic;
import com.hdl.photovoltaic.other.HdlUniLogic;
import com.hdl.photovoltaic.ui.bean.HouseIdBean;
@@ -29,15 +32,13 @@
import com.hdl.photovoltaic.uni.HDLUniMP;
import com.hdl.photovoltaic.uni.HDLUniMPSDKManager;
import com.hdl.photovoltaic.utils.BadgeUtils;
-import com.hdl.photovoltaic.utils.LocalManageUtil;
import com.hdl.photovoltaic.utils.SharedPreUtils;
import com.hdl.photovoltaic.widget.ConfirmationCancelDialog;
-import com.umeng.commonsdk.UMConfigure;
+//import com.umeng.commonsdk.UMConfigure;
import java.util.List;
import java.util.Objects;
-import cn.jpush.android.api.JPushInterface;
/**
@@ -52,7 +53,7 @@
@Override
public void onBindView(Bundle savedInstanceState) {
- Log.d("StartActivity", "onBindView");
+ Log.d("StartActivity====", "onBindView");
setStatusBarTranslucent();
getWindow().setNavigationBarColor(getColor(R.color.text_FF000000));
BadgeUtils.cancelAllNotifications(_mActivity);
@@ -183,7 +184,7 @@
int startIndex2 = s.lastIndexOf("銆�");
int endIndex2 = s.lastIndexOf("銆�") + 1;
- if (UserConfigManage.getInstance().getCurrentAppLanguage().equals(LocalManageUtil.en)) {
+ if (UserConfigManage.getInstance().getCurrentAppLanguage().equals(Languages.en)) {
s = s.replace("銆�", "").replace("銆�", "");
endIndex1 -= 1;
startIndex2 -= 2;//绉婚櫎"銆�"鍜�"銆�"鎬婚暱搴﹀彂鐢熷彉鍖栵紝绱㈠紩涔熸敼鍙�;
@@ -207,8 +208,8 @@
super.updateDrawState(ds);
//璁剧疆瀛椾綋棰滆壊
ds.setColor(getResources().getColor(R.color.text_38C494, null));
- // 鍘绘帀涓嬪垝绾�
- ds.setUnderlineText(!UserConfigManage.getInstance().isZh());
+ // 鍘绘帀涓嬪垝绾�(涓枃淇濈暀涓嬪垝绾�)
+ ds.setUnderlineText(!UserConfigManage.getInstance().getCurrentAppLanguage().equals(Languages.zh));
}
@@ -231,7 +232,7 @@
//璁剧疆瀛椾綋棰滆壊
ds.setColor(getResources().getColor(R.color.text_38C494, null));
// 鍘绘帀涓嬪垝绾�
- ds.setUnderlineText(!UserConfigManage.getInstance().isZh());
+ ds.setUnderlineText(!UserConfigManage.getInstance().getCurrentAppLanguage().equals(Languages.zh));
}
@@ -260,32 +261,23 @@
}
HDLApp.getInstance().isStartInitThirdSDK = true;
//鍒濆鍖栧弸鐩烻DK
- initUMengSDK();
- //鍒濆鍖栨瀬鍏夋帹閫�
- initJPush();
-
+ // initUMengSDK();
}
- /**
- * 鍒濆鍖栨瀬鍏塖DK
- */
- private void initJPush() {
- JPushInterface.setDebugMode(true);
- JPushInterface.init(getBaseContext());
- }
+
/**
* 鍒濆鍖栧弸鐩烻DK锛屾姄闂��鏃ュ織
* 闆嗘垚鏁欑▼鍦板潃锛歨ttps://developer.umeng.com/docs/119267/detail/118588
*/
private void initUMengSDK() {
- UMConfigure.preInit(this, "6801aec0bc47b67d833fd76d", "XenterraSolar");
- //appkey鍜宑hannl蹇呴』淇濇寔鍜岄鍒濆鍖栦竴鑷达紒锛侊紒
- //deviceType锛氳澶囩被鍨嬶紝UMConfigure.DEVICE_TYPE_PHONE涓烘墜鏈恒�乁MConfigure.DEVICE_TYPE_BOX涓虹洅瀛�
- //pushSecret锛歅ush鎺ㄩ�佷笟鍔$殑secret
- UMConfigure.init(this, "6801aec0bc47b67d833fd76d", "XenterraSolar", UMConfigure.DEVICE_TYPE_PHONE, "");
- UMConfigure.setLogEnabled(false);//AppConfigManage.isDebug()
+// UMConfigure.preInit(this, "6801aec0bc47b67d833fd76d", "XenterraSolar");
+// //appkey鍜宑hannl蹇呴』淇濇寔鍜岄鍒濆鍖栦竴鑷达紒锛侊紒
+// //deviceType锛氳澶囩被鍨嬶紝UMConfigure.DEVICE_TYPE_PHONE涓烘墜鏈恒�乁MConfigure.DEVICE_TYPE_BOX涓虹洅瀛�
+// //pushSecret锛歅ush鎺ㄩ�佷笟鍔$殑secret
+// UMConfigure.init(this, "6801aec0bc47b67d833fd76d", "XenterraSolar", UMConfigure.DEVICE_TYPE_PHONE, "");
+// UMConfigure.setLogEnabled(false);//AppConfigManage.isDebug()
}
/**
@@ -297,8 +289,10 @@
try {
// 澶勭悊浠庨�氱煡鐐瑰嚮甯︽潵鐨勬暟鎹紝杩欓噷鑾峰彇鏁版嵁锛岀劧鍚庨�忎紶缁欎富鐣岄潰鍋氬鐞�
if (getIntent().getExtras() != null) {
+ Log.d("鏉ヨ嚜鐐瑰嚮娑堟伅鐨勬暟鎹�===", JSONObject.toJSONString(getIntent().getExtras()));
for (String key : getIntent().getExtras().keySet()) {
- if (key.equals("pushData")) {
+ Log.d("鏉ヨ嚜鐐瑰嚮娑堟伅鐨勬暟鎹�", "key: " + key + " value: " + getIntent().getExtras().get(key));
+ if (key.equals("pushData") || key.equals("extraMap")) {
return Objects.requireNonNull(getIntent().getExtras().get(key)).toString();
}
}
@@ -308,6 +302,5 @@
}
return "";
}
-
}
--
Gitblit v1.8.0