09-13 16:24:00.996: ERROR/AndroidRuntime(929): FATAL EXCEPTION: main
09-13 16:24:00.996: ERROR/AndroidRuntime(929): android.view.InflateException: Binary XML file line #2: Error inflating class com.android.launcher2.AllApps2D$BackHomeZone
09-13 16:24:00.996: ERROR/AndroidRuntime(929): at android.view.LayoutInflater.createView(LayoutInflater.java:503)
09-13 16:24:00.996: ERROR/AndroidRuntime(929): at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:565)
09-13 16:24:00.996: ERROR/AndroidRuntime(929): at android.view.LayoutInflater.inflate(LayoutInflater.java:385)
09-13 16:24:00.996: ERROR/AndroidRuntime(929): at android.view.LayoutInflater.inflate(LayoutInflater.java:320)
09-13 16:24:00.996: ERROR/AndroidRuntime(929): at android.view.LayoutInflater.inflate(LayoutInflater.java:276)
09-13 16:24:00.996: ERROR/AndroidRuntime(929): at com.android.launcher2.AllApps2D.onItemLongClick(AllApps2D.java:264)
09-13 16:24:00.996
Error inflating class错误
最新推荐文章于 2023-05-12 15:28:05 发布
本文介绍了在Android开发中遇到'Error inflating class'错误的两种常见原因:缺少默认构造函数和内部类未声明为static。同时,针对自定义组件,强调了如果组件为内部类,需要使用view作为XML布局的节点,并通过class属性指定内部类引用。
摘要由CSDN通过智能技术生成