【问题标题】:Application closes when rotate Gmaps V2旋转 Gmaps V2 时应用程序关闭
【发布时间】:2013-09-19 14:33:11
【问题描述】:

我有一个带有 Gmaps 的应用程序,它在纵向模式下运行良好,但在我旋转到横向模式时关闭,它不会崩溃,只是关闭!

在 LogCat 中我得到了这个,

09-19 16:24:24.056: W/ResourceType(20122): getEntry failing because entryIndex 939 is beyond type entryCount 1
09-19 16:24:24.056: W/ResourceType(20122): Failure getting entry for 0x7f0b03ab (t=10 e=939) in package 0 (error -2147483647)
09-19 16:24:24.056: E/GooglePlayServicesUtil(20122): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.

但是 google play 服务已经存在,而且是最新的。

有人知道吗?谢谢

【问题讨论】:

  • 可能与这里的讨论有关:stackoverflow.com/questions/18068627/…
  • 这不是同一个错误!我的应用程序显示,一切正常,直到我尝试旋转并关闭它,它不会崩溃!
  • 根据您发布的内容,这是相同的错误,但数字不同。你能分享更多的 Logcat 输出吗?您提到应用“不会崩溃”,但是否生成了堆栈跟踪?
  • 这一切都在 LogCat 上。

标签: android google-maps google-maps-api-2 google-play-services


【解决方案1】:

像这样为您的活动处理清单中的屏幕方向更改

android:configChanges="orientation|keyboardHidden"

同时处理屏幕方向变化和键盘可用性变化:

【讨论】:

    猜你喜欢
    • 2010-12-15
    • 1970-01-01
    • 2022-11-10
    • 2013-04-26
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多