调试运行launcher源码 2
Android launcher – 调试运行launcher源码 1调试没有报错,但还是编译不起来。
修改:
删除AndroidManifest.xml中的android:sharedUserId=”android.uid.shared”
编译起来,运行不起来
- :: E/AndroidRuntime(): FATAL EXCEPTION: main
- :: E/AndroidRuntime(): Process: android.process.acore, PID:
- :: E/AndroidRuntime(): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.launcher/com.android.launcher.Launcher}: android.view.InflateException: Binary XML file line #26: Binary XML file line #26: Error inflating class com.android.launcher.Workspace
//... ....
- :: E/AndroidRuntime(): ... more
- :: E/AndroidRuntime(): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean android.graphics.Bitmap.hasAlpha()' on a null object reference
- :: E/AndroidRuntime(): at com.android.launcher.Workspace.isOpaque(Workspace.java:)
- :: E/AndroidRuntime(): at android.view.View.invalidateInternal(View.java:)
- :: E/AndroidRuntime(): at android.view.View.invalidate(View.java:)
- :: E/AndroidRuntime(): at android.view.View.setFlags(View.java:)
- :: E/AndroidRuntime(): at android.view.ViewGroup.initViewGroup(ViewGroup.java:)
- :: E/AndroidRuntime(): at android.view.ViewGroup.<init>(ViewGroup.java:)
- :: E/AndroidRuntime(): at android.view.ViewGroup.<init>(ViewGroup.java:)
- :: E/AndroidRuntime(): at com.android.launcher.Workspace.<init>(Workspace.java:)
- :: E/AndroidRuntime(): at com.android.launcher.Workspace.<init>(Workspace.java:)
- :: E/AndroidRuntime(): ... more
报空:
- :: E/AndroidRuntime(): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean android.graphics.Bitmap.hasAlpha()' on a null object reference
06-10 17:: E/AndroidRuntime(): at com.android.launcher.Workspace.isOpaque(Workspace.java:)
修改:
Launcher源码运行截图
下载