Reputation: 1
I'm writing ICS+ app and it works fine on Nexus S, Nexus Galaxy, Nexus 7, Galaxy Tab, Galaxy S3 and bunch of other devices. Yesterday I got Nexus 4 and the app crashes during the startup.
The stacktrace is below. I looked in the sources (android.view.ViewConfiguration) and what the device tries to do is to get fading marquee resource - here is
mFadingMarqueeEnabled = res.getBoolean(
com.android.internal.R.bool.config_ui_enableFadingMarquee);
Does anyone has any idea what might be happening?
02-04 17:54:09.727: E/AndroidRuntime(16932): java.lang.RuntimeException: Unable to start activity ComponentInfo{myapp/myapp.Main}: android.content.res.Resources$NotFoundException: Resource ID #0x1110013
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2180)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2230)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.ActivityThread.access$600(ActivityThread.java:141)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1234)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.os.Handler.dispatchMessage(Handler.java:99)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.os.Looper.loop(Looper.java:137)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.ActivityThread.main(ActivityThread.java:5039)
02-04 17:54:09.727: E/AndroidRuntime(16932): at java.lang.reflect.Method.invokeNative(Native Method)
02-04 17:54:09.727: E/AndroidRuntime(16932): at java.lang.reflect.Method.invoke(Method.java:511)
02-04 17:54:09.727: E/AndroidRuntime(16932): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
02-04 17:54:09.727: E/AndroidRuntime(16932): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
02-04 17:54:09.727: E/AndroidRuntime(16932): at dalvik.system.NativeStart.main(Native Method)
02-04 17:54:09.727: E/AndroidRuntime(16932): Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x1110013
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.content.res.Resources.getValue(Resources.java:1014)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.content.res.Resources.getBoolean(Resources.java:796)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.view.ViewConfiguration.<init>(ViewConfiguration.java:301)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.view.ViewConfiguration.get(ViewConfiguration.java:323)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.view.View.<init>(View.java:3234)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.view.ViewGroup.<init>(ViewGroup.java:420)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.widget.FrameLayout.<init>(FrameLayout.java:93)
02-04 17:54:09.727: E/AndroidRuntime(16932): at com.android.internal.policy.impl.PhoneWindow$DecorView.<init>(PhoneWindow.java:1816)
02-04 17:54:09.727: E/AndroidRuntime(16932): at com.android.internal.policy.impl.PhoneWindow.generateDecor(PhoneWindow.java:2585)
02-04 17:54:09.727: E/AndroidRuntime(16932): at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:2867)
02-04 17:54:09.727: E/AndroidRuntime(16932): at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1568)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.Activity.initActionBar(Activity.java:1861)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.Activity.getActionBar(Activity.java:1848)
02-04 17:54:09.727: E/AndroidRuntime(16932): at myapp.Main.onCreate(Main.java:75)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.Activity.performCreate(Activity.java:5104)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1080)
02-04 17:54:09.727: E/AndroidRuntime(16932): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2144)
02-04 17:54:09.727: E/AndroidRuntime(16932): ... 11 more
Upvotes: 0
Views: 445
Reputation: 83719
I wouldn't use the internal resources because it would appear they are not public (and are subject to change).
have a look at The import com.android.internal.R cannot be resolved for more information on how you would get it to work the way you want.
Upvotes: 1
Reputation: 1891
It seems like the android framework installed on the LG Nexus 4 lacks com.android.internal.R.bool.config_ui_enableFadingMarquee
Upvotes: 0