AdWhirl 与 Admob 错误修复

发布于 2024-12-25 08:19:57 字数 2486 浏览 1 评论 0原文

已更新到最新版本的 AdWhirl 和 AdMob SDK,但在 Android 2.1-update1 中从 AdMob SDK 中收到已知错误。在此帖子中找到 https://groups.google.com /forum/#!topic/google-admob-ads-sdk/cNxRgIUHJH0

但它仅指 AdMob 修复而不是 AdWhirl 任何线索是否可以对 AdWhirl SDK 进行更改来解决此问题?

提前致谢!

java.lang.NullPointerException
    at android.webkit.WebView.getSettings(WebView.java:2791)
    at android.webkit.WebView.onWindowFocusChanged(WebView.java:3616)
    at android.view.View.dispatchWindowFocusChanged(View.java:3764)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:754)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewRoot.handleMessage(ViewRoot.java:1819)
    at android.os.Handler.dispatchMessage(Handler.java:99)
    at android.os.Looper.loop(Looper.java:123)
    at android.app.ActivityThread.main(ActivityThread.java:4370)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:521)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
    at dalvik.system.NativeStart.main(Native Method)

这个怎么样:

java.lang.NullPointerException
at com.adwhirl.AdWhirlLayout.handleAd(AdWhirlLayout.java:227)
at com.adwhirl.AdWhirlLayout.access$3(AdWhirlLayout.java:215)
at com.adwhirl.AdWhirlLayout$HandleAdRunnable.run(AdWhirlLayout.java:410)
at android.os.Handler.handleCallback(Handler.java:587)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:130)
at android.app.ActivityThread.main(ActivityThread.java:3691)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:507)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:670)
at dalvik.system.NativeStart.main(Native Method)

Updated to the latest version of AdWhirl and AdMob SDK but getting a known error from the AdMob SDK in Android 2.1-update1. Found in this thread https://groups.google.com/forum/#!topic/google-admob-ads-sdk/cNxRgIUHJH0

but it refers to only and AdMob fix not AdWhirl any clue what changes can be made to the AdWhirl SDK to fix this?

Thanks In Advance!

java.lang.NullPointerException
    at android.webkit.WebView.getSettings(WebView.java:2791)
    at android.webkit.WebView.onWindowFocusChanged(WebView.java:3616)
    at android.view.View.dispatchWindowFocusChanged(View.java:3764)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:754)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:758)
    at android.view.ViewRoot.handleMessage(ViewRoot.java:1819)
    at android.os.Handler.dispatchMessage(Handler.java:99)
    at android.os.Looper.loop(Looper.java:123)
    at android.app.ActivityThread.main(ActivityThread.java:4370)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:521)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
    at dalvik.system.NativeStart.main(Native Method)

How about this one:

java.lang.NullPointerException
at com.adwhirl.AdWhirlLayout.handleAd(AdWhirlLayout.java:227)
at com.adwhirl.AdWhirlLayout.access$3(AdWhirlLayout.java:215)
at com.adwhirl.AdWhirlLayout$HandleAdRunnable.run(AdWhirlLayout.java:410)
at android.os.Handler.handleCallback(Handler.java:587)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:130)
at android.app.ActivityThread.main(ActivityThread.java:3691)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:507)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:670)
at dalvik.system.NativeStart.main(Native Method)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

浅忆 2025-01-01 08:19:57

问题不在于 AdWhirl 代码,甚至不在于 AdMob 代码。这是 Android WebView 中的 NullPointerException,并且 AdMob/AdWhirl 代码没有已知的解决方法。这种情况不应该经常发生,但如果这确实会破坏交易,您可能需要减少发送到 AdMob 的请求数量。

The issue is not in the AdWhirl code, or even the AdMob code. This is a NullPointerException in the Android WebView, and there is no known workaround for the AdMob/AdWhirl code. This shouldn't be happening that often, but if it really is a deal breaker, you may want to turn down the number of requests you're sending to AdMob.

掀纱窥君容 2025-01-01 08:19:57

是的,我也有这个问题。

我的解决方法:扩展 AdWhirlLayout、重写dispatchWindowFocusChanged 以及发生此异常的所有其他方法并捕获异常。

Yes, I also have this problem.

My workaround: extend AdWhirlLayout, override dispatchWindowFocusChanged and every other method that have this exception occurring and catch the exception.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文