From 8b43d4e1190fc9e2261be0579e53cc6c2987f946 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期四, 27 十一月 2025 19:37:56 +0800
Subject: [PATCH] 2025年11月27日19:37:50 备份代码
---
app/src/main/java/com/hdl/photovoltaic/ui/me/WebActivity.java | 34 ++++++++++++++++++----------------
1 files changed, 18 insertions(+), 16 deletions(-)
diff --git a/app/src/main/java/com/hdl/photovoltaic/ui/me/WebActivity.java b/app/src/main/java/com/hdl/photovoltaic/ui/me/WebActivity.java
index d4f11f8..1b0a55a 100644
--- a/app/src/main/java/com/hdl/photovoltaic/ui/me/WebActivity.java
+++ b/app/src/main/java/com/hdl/photovoltaic/ui/me/WebActivity.java
@@ -1,14 +1,15 @@
package com.hdl.photovoltaic.ui.me;
+import android.annotation.SuppressLint;
import android.os.Bundle;
import android.view.View;
-import com.hdl.photovoltaic.HDLApp;
import com.hdl.photovoltaic.R;
import com.hdl.photovoltaic.base.CustomBaseActivity;
import com.hdl.photovoltaic.config.UserConfigManage;
import com.hdl.photovoltaic.databinding.ActivityWebBinding;
+import com.hdl.photovoltaic.enums.Languages;
import com.hdl.photovoltaic.utils.LocalManageUtil;
/**
@@ -36,8 +37,8 @@
@Override
public void onBindView(Bundle savedInstanceState) {
- setNotificationBarBackgroundColor(CustomBaseActivity.CustomColor.white);
- setStatusBarTextColor();
+ setStatusBarTranslucent();
+ getWindow().setNavigationBarColor(getColor(R.color.text_FF000000));
this.typeIntValue = getIntent().getIntExtra("type", 0);
//鍒濆鍖�
initView();
@@ -46,7 +47,7 @@
}
private void initEvent() {
- viewBinding.toolbarTopFragmentHouseListRl.topBackBtn.setOnClickListener(new View.OnClickListener() {
+ viewBinding.toolbarTopRl.topBackLl.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
finish();
@@ -54,33 +55,34 @@
});
}
+ @SuppressLint("SetJavaScriptEnabled")
private void initView() {
+ viewBinding.contentView.getSettings().setJavaScriptEnabled(true);
+ //xml閲岄潰璁剧疆鑳屾櫙鏃犳晥
+ viewBinding.contentView.setBackgroundColor(getColor(R.color.text_FF000000));
if (this.typeIntValue == 0) {
- viewBinding.toolbarTopFragmentHouseListRl.topTitleTv.setText(R.string.app_service_agreement);
+ viewBinding.toolbarTopRl.topTitleTv.setText(R.string.app_service_agreement);
} else {
- viewBinding.toolbarTopFragmentHouseListRl.topTitleTv.setText(R.string.app_privacy_policy);
+ viewBinding.toolbarTopRl.topTitleTv.setText(R.string.app_privacy_policy);
}
- viewBinding.toolbarTopFragmentHouseListRl.topTitleTv.setTextColor(getResources().getColor(R.color.text_030D1C, null));
- viewBinding.toolbarTopFragmentHouseListRl.topBackBtn.setVisibility(View.VISIBLE);
- viewBinding.toolbarTopFragmentHouseListRl.topBarView.setBackgroundColor(getResources().getColor(R.color.text_FFFFFFFF, null));
-
- if (UserConfigManage.getInstance().getCurrentAppLanguage().equals(LocalManageUtil.zh)) {
+ viewBinding.toolbarTopRl.topBackLl.setVisibility(View.VISIBLE);
+ if (UserConfigManage.getInstance().getCurrentAppLanguage().equals(Languages.zh)) {
//涓枃
if (this.typeIntValue == 0) {
- //鐢ㄦ埛鍗忚
- viewBinding.contentView.loadUrl("https://developer.hdlcontrol.com/GreenSmartEnergy__UserAgreement.html");
+ //鐢ㄦ埛鍗忚 https://nearest.hdlcontrol.com
+ viewBinding.contentView.loadUrl("https://common.hdlcontrol.com/common-h5/#/pages/greenEnergyAgreement/userAgreement");
} else {
//闅愮鍗忚
- viewBinding.contentView.loadUrl("https://developer.hdlcontrol.com/GreenSmartEnergy__PrivacyPolicy.html");
+ viewBinding.contentView.loadUrl("https://common.hdlcontrol.com/common-h5/#/pages/greenEnergyAgreement/privacyAgreement");
}
} else {
//鑻辨枃
if (this.typeIntValue == 0) {
//鐢ㄦ埛鍗忚
- viewBinding.contentView.loadUrl("https://developer.hdlcontrol.com/GreenSmartEnergy__UserAgreement-En.html");
+ viewBinding.contentView.loadUrl("https://common.hdlcontrol.com/common-h5/#/pages/greenEnergyAgreement/userAgreementEn");
} else {
//闅愮鍗忚
- viewBinding.contentView.loadUrl("https://developer.hdlcontrol.com/GreenSmartEnergy_PrivacyPolicy-En.html");
+ viewBinding.contentView.loadUrl("https://common.hdlcontrol.com/common-h5/#/pages/greenEnergyAgreement/privacyAgreementEn");
}
}
--
Gitblit v1.8.0