From 5dcdd3fc5f24899fa3bc607b39a3f9e07ff6506b Mon Sep 17 00:00:00 2001 From: 18401019693 Date: Wed, 19 Apr 2023 16:38:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=9A=E8=AF=AD=E8=A8=80=E5=88=87=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/yunbao/common/activity/WebViewActivity.java | 2 +- .../java/com/yunbao/live/activity/WebViewActivityMedal.java | 3 ++- .../main/java/com/yunbao/main/activity/RewardActivity.java | 4 ++-- .../java/com/yunbao/main/activity/ZhuangBanActivity.java | 6 +++--- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/common/src/main/java/com/yunbao/common/activity/WebViewActivity.java b/common/src/main/java/com/yunbao/common/activity/WebViewActivity.java index cd2fd7c58..246071e0f 100644 --- a/common/src/main/java/com/yunbao/common/activity/WebViewActivity.java +++ b/common/src/main/java/com/yunbao/common/activity/WebViewActivity.java @@ -245,7 +245,7 @@ public class WebViewActivity extends AbsActivity { } public static void forward(Context context, String url) { - forward(context, url+ "&isZh=" + ((IMLoginManager.get(CommonAppContext.sInstance.getBaseContext()).getLocaleLanguage() == Locale.SIMPLIFIED_CHINESE) ? "1" : "0"), true); + forward(context, url, true); } @Override diff --git a/live/src/main/java/com/yunbao/live/activity/WebViewActivityMedal.java b/live/src/main/java/com/yunbao/live/activity/WebViewActivityMedal.java index 1f2dec0b1..6f7d9ea3e 100644 --- a/live/src/main/java/com/yunbao/live/activity/WebViewActivityMedal.java +++ b/live/src/main/java/com/yunbao/live/activity/WebViewActivityMedal.java @@ -24,6 +24,7 @@ import androidx.annotation.RequiresApi; import com.alibaba.fastjson.JSON; import com.yunbao.common.CommonAppConfig; +import com.yunbao.common.CommonAppContext; import com.yunbao.common.Constants; import com.yunbao.common.HtmlConfig; import com.yunbao.common.R; @@ -293,7 +294,7 @@ public class WebViewActivityMedal extends AbsActivity { url += "&uid=" + CommonAppConfig.getInstance().getUid() + "&token=" + CommonAppConfig.getInstance().getToken(); } Intent intent = new Intent(context, WebViewActivityMedal.class); - intent.putExtra(Constants.URL, url); + intent.putExtra(Constants.URL, url+ "&isZh=" + ((IMLoginManager.get(CommonAppContext.sInstance.getBaseContext()).getLocaleLanguage() == Locale.SIMPLIFIED_CHINESE) ? "1" : "0")); context.startActivity(intent); } diff --git a/main/src/main/java/com/yunbao/main/activity/RewardActivity.java b/main/src/main/java/com/yunbao/main/activity/RewardActivity.java index 204e8e4d1..185f65de6 100644 --- a/main/src/main/java/com/yunbao/main/activity/RewardActivity.java +++ b/main/src/main/java/com/yunbao/main/activity/RewardActivity.java @@ -320,12 +320,12 @@ public class RewardActivity extends AbsActivity { } Intent intent = new Intent(context, RewardActivity.class); Log.i("tag", url); - intent.putExtra(Constants.URL, url); + intent.putExtra(Constants.URL, url+ "&isZh=" + ((IMLoginManager.get(CommonAppContext.sInstance.getBaseContext()).getLocaleLanguage() == Locale.SIMPLIFIED_CHINESE) ? "1" : "0")); context.startActivity(intent); } public static void forward(Context context, String url) { - forward(context, url+ "&isZh=" + ((IMLoginManager.get(CommonAppContext.sInstance.getBaseContext()).getLocaleLanguage() == Locale.SIMPLIFIED_CHINESE) ? "1" : "0"), true); + forward(context, url, true); } @Override diff --git a/main/src/main/java/com/yunbao/main/activity/ZhuangBanActivity.java b/main/src/main/java/com/yunbao/main/activity/ZhuangBanActivity.java index b4769ab38..af8c3a468 100644 --- a/main/src/main/java/com/yunbao/main/activity/ZhuangBanActivity.java +++ b/main/src/main/java/com/yunbao/main/activity/ZhuangBanActivity.java @@ -282,7 +282,7 @@ public class ZhuangBanActivity extends AbsActivity { } Intent intent = new Intent(context, ZhuangBanActivity.class); Log.i("tag1212", url); - intent.putExtra(Constants.URL, url); + intent.putExtra(Constants.URL, url+ "&isZh=" + ((IMLoginManager.get(CommonAppContext.sInstance.getBaseContext()).getLocaleLanguage() == Locale.SIMPLIFIED_CHINESE) ? "1" : "0")); if (url.contains("Noble/index.html") || url.contains("Grade/index.html")) { intent.putExtra("title", ""); } @@ -290,7 +290,7 @@ public class ZhuangBanActivity extends AbsActivity { } public static void forward(Context context, String url) { - forward(context, url+ "&isZh=" + ((IMLoginManager.get(CommonAppContext.sInstance.getBaseContext()).getLocaleLanguage() == Locale.SIMPLIFIED_CHINESE) ? "1" : "0"), true); + forward(context, url, true); } @Override @@ -310,7 +310,7 @@ public class ZhuangBanActivity extends AbsActivity { /** * 复制到剪贴板 */ - private void copy(String content) { + private void copy(String content) { ClipboardManager cm = (ClipboardManager) getSystemService(CLIPBOARD_SERVICE); ClipData clipData = ClipData.newPlainText("text", content); cm.setPrimaryClip(clipData);