From 0a328c4632968fd1dbeb18f61c39d92789320ac2 Mon Sep 17 00:00:00 2001 From: yaowei Date: Tue, 29 Sep 2020 14:21:51 +0800 Subject: [PATCH] Toast: add not support video play toast step one, check current scene is the vedio-play-using-webview activity step two, check is the dingding apk then display the toast --- core/java/android/app/Activity.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/core/java/android/app/Activity.java b/core/java/android/app/Activity.java index 69e0f4ed..a014da33 100644 --- a/core/java/android/app/Activity.java +++ b/core/java/android/app/Activity.java @@ -4590,6 +4590,16 @@ public class Activity extends ContextThemeWrapper } else if (notPayList.containsKey(nComponent)) { isPay = true; } + + String lowerCaseComponent = nComponent.toLowerCase(); + String lowerCaseParentActivity = mIntent.toString().toLowerCase(); + if (lowerCaseComponent.indexOf("com.alibaba.android.rimet/com.alibaba.lightapp.runtime.activity.commonwebviewactivity", 0) > 0) { + if (lowerCaseParentActivity.indexOf("com.alibaba.android.rimet/com.alibaba.lightapp.runtime.ariver.theoneactivity", 0) > 0) { + Toast toast = Toast.makeText(this, "本页面中部分视频暂不支持播放", Toast.LENGTH_LONG); + toast.setGravity(Gravity.CENTER, 0, 0); + toast.show(); + } + } } else { String nIntent = intent.toString(); if (nIntent.indexOf("quickpass/qrcode?entry=homenav", 0) > 0) { -- Gitee