gpt4 book ai didi

安卓 4.0.3 ScrollingTabContainerView NullPointerException

转载 作者:塔克拉玛干 更新时间:2023-11-02 23:31:25 25 4
gpt4 key购买 nike

我们的 Android 应用程序随机崩溃(很难重现该问题)并显示以下堆栈跟踪。当设备的方向从 logcat 日志从纵向更改为横向时,就会看到这一点。此问题也出现在 Android 4.0.3 版本的设备上。所以想检查它是否是 4.0.3 的已知问题?从代码中不确定如何调试此问题,因为堆栈跟踪完全是 Android 平台,不涉及 App 代码。

02-21 17:44:01.761 E/UncaughtException( 3344): java.lang.NullPointerException
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.widget.ScrollingTabContainerView.onItemSelected(ScrollingTabContainerView.java:352)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.AdapterView.fireOnSelected(AdapterView.java:882)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.AdapterView.selectionChanged(AdapterView.java:865)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.AdapterView.checkSelectionChanged(AdapterView.java:1017)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.AdapterView.handleDataChanged(AdapterView.java:999)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.AbsSpinner.onMeasure(AbsSpinner.java:179)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.Spinner.onMeasure(Spinner.java:285)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.View.measure(View.java:12723)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.HorizontalScrollView.measureChildWithMargins(HorizontalScrollView.java:1159)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.FrameLayout.onMeasure(FrameLayout.java:293)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.HorizontalScrollView.onMeasure(HorizontalScrollView.java:303)
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.widget.ScrollingTabContainerView.onMeasure(ScrollingTabContainerView.java:117)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.View.measure(View.java:12723)
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.widget.ActionBarView.onMeasure(ActionBarView.java:878)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.View.measure(View.java:12723)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:4698)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.FrameLayout.onMeasure(FrameLayout.java:293)
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.widget.ActionBarContainer.onMeasure(ActionBarContainer.java:173)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.View.measure(View.java:12723)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:4698)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1369)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.LinearLayout.measureVertical(LinearLayout.java:660)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.LinearLayout.onMeasure(LinearLayout.java:553)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.View.measure(View.java:12723)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:4698)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.widget.FrameLayout.onMeasure(FrameLayout.java:293)
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.policy.impl.PhoneWindow$DecorView.onMeasure(PhoneWindow.java:2092)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.View.measure(View.java:12723)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1064)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.view.ViewRootImpl.handleMessage(ViewRootImpl.java:2442)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.os.Handler.dispatchMessage(Handler.java:99)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.os.Looper.loop(Looper.java:137)
02-21 17:44:01.761 E/UncaughtException( 3344): at android.app.ActivityThread.main(ActivityThread.java:4424)
02-21 17:44:01.761 E/UncaughtException( 3344): at java.lang.reflect.Method.invokeNative(Native Method)
02-21 17:44:01.761 E/UncaughtException( 3344): at java.lang.reflect.Method.invoke(Method.java:511)
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
02-21 17:44:01.761 E/UncaughtException( 3344): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
02-21 17:44:01.761 E/UncaughtException( 3344): at dalvik.system.NativeStart.main(Native Method)

最佳答案

我真的不知道这个错误是从哪里来的。我通过更改

修复了它
    <item name="android:windowActionBarOverlay">false</item>

进入

    <item name="android:windowActionBarOverlay">true</item>

我的 Android v15 主要风格。对于这个 Android 版本,它让我的应用程序变得不那么漂亮了,但这没关系。我希望这只是一个 4.0.3 错误,我有 6 台其他 Android 版本的平板电脑运行良好。

关于安卓 4.0.3 ScrollingTabContainerView NullPointerException,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15084430/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com