Android app layout inflating error in below SDK 22 - android

I have two Genymotion devices installed on my PC. One has SDK 19 and the other 22. The example app and the app I'm developing using this library works pretty well on the device with SDK 22. However they both crash on the device with SDK 18. I also have a real device with SDK 19 and they also crash on that device too. The stack trace is as following:
10-07 12:24:12.684 9948-9948/io.github.meness.easyintro.app E/AndroidRuntime: FATAL EXCEPTION: main
Process: io.github.meness.easyintro.app, PID: 9948
java.lang.RuntimeException: Unable to start activity ComponentInfo{io.github.meness.easyintro.app/io.github.meness.easyintro.app.MyEasyIntro}: android.view.InflateException: Binary XML file line #24: Error inflating class io.github.meness.easyintro.views.LeftToggleIndicator
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2235)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2285)
at android.app.ActivityThread.access$800(ActivityThread.java:138)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1236)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:149)
at android.app.ActivityThread.main(ActivityThread.java:5061)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:787)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:603)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #24: Error inflating class io.github.meness.easyintro.views.LeftToggleIndicator
at android.view.LayoutInflater.createView(LayoutInflater.java:620)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at android.support.v7.widget.ViewStubCompat.inflate(ViewStubCompat.java:200)
at io.github.meness.easyintro.EasyIntroCarouselFragment.inflateIndicatorContainer(EasyIntroCarouselFragment.java:732)
at io.github.meness.easyintro.EasyIntroCarouselFragment.onViewCreated(EasyIntroCarouselFragment.java:680)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1086)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1252)
at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:742)
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1617)
at android.support.v4.app.FragmentController.execPendingActions(FragmentController.java:339)
at android.support.v4.app.FragmentActivity.onStart(FragmentActivity.java:601)
at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1171)
at android.app.Activity.performStart(Activity.java:5241)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2208)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2285) 
at android.app.ActivityThread.access$800(ActivityThread.java:138) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1236) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:149) 
at android.app.ActivityThread.main(ActivityThread.java:5061) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:787) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:603) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:594)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.support.v7.widget.ViewStubCompat.inflate(ViewStubCompat.java:200) 
at io.github.meness.easyintro.EasyIntroCarouselFragment.inflateIndicatorContainer(EasyIntroCarouselFragment.java:732) 
at io.github.meness.easyintro.EasyIntroCarouselFragment.onViewCreated(EasyIntroCarouselFragment.java:680) 
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1086) 
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1252) 
at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:742) 
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1617) 
at android.support.v4.app.FragmentController.execPendingActions(FragmentController.java:339) 
at android.support.v4.app.FragmentActivity.onStart(FragmentActivity.java:601) 
at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1171) 
at android.app.Activity.performStart(Activity.java:5241) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2208) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2285) 
at android.app.ActivityThread.access$800(ActivityThread.java:138) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1236) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:149) 
at android.app.ActivityThread.main(ActivityThread.java:5061) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:787) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:603) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: android.content.res.Resources$NotFoundException: File res/drawable/toggle_indicators_bg.xml from drawable resource ID #0x7f020050
at android.content.res.Resources.loadDrawable(Resources.java:2097)
at android.content.res.TypedArray.getDrawable(TypedArray.java:602)
at android.view.View.<init>(View.java:3554)
at android.widget.ImageView.<init>(ImageView.java:123)
at android.widget.ImageButton.<init>(ImageButton.java:87)
at android.support.v7.widget.AppCompatImageButton.<init>(AppCompatImageButton.java:57)
at io.github.meness.easyintro.views.AbstractToggleIndicator.<init>(AbstractToggleIndicator.java:0)
at io.github.meness.easyintro.views.AbstractToggleIndicator.<init>(AbstractToggleIndicator.java:0)
at io.github.meness.easyintro.views.LeftToggleIndicator.<init>(LeftToggleIndicator.java:0)
at java.lang.reflect.Constructor.constructNative(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) 
at android.view.LayoutInflater.createView(LayoutInflater.java:594) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.support.v7.widget.ViewStubCompat.inflate(ViewStubCompat.java:200) 
at io.github.meness.easyintro.EasyIntroCarouselFragment.inflateIndicatorContainer(EasyIntroCarouselFragment.java:732) 
at io.github.meness.easyintro.EasyIntroCarouselFragment.onViewCreated(EasyIntroCarouselFragment.java:680) 
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1086) 
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1252) 
at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:742) 
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1617) 
at android.support.v4.app.FragmentController.execPendingActions(FragmentController.java:339) 
at android.support.v4.app.FragmentActivity.onStart(FragmentActivity.java:601) 
at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1171) 
at android.app.Activity.performStart(Activity.java:5241) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2208) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2285) 
at android.app.ActivityThread.access$800(ActivityThread.java:138) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1236) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:149) 
at android.app.ActivityThread.main(ActivityThread.java:5061) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:787) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:603) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.UnsupportedOperationException: Can't convert to color: type=0x2
at android.content.res.TypedArray.getColor(TypedArray.java:327)
at android.graphics.drawable.GradientDrawable.inflate(GradientDrawable.java:970)
at android.graphics.drawable.Drawable.createFromXmlInner(Drawable.java:937)
at andr
My XML:
<io.github.meness.easyintro.views.LeftToggleIndicator
android:id="#+id/leftIndicator"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:layout_marginEnd="5dp"
android:visibility="invisible"
android:layout_marginRight="5dp"
android:background="?attr/toggleIndicatorsBackground"
android:padding="4dp"
android:src="#drawable/ic_keyboard_arrow_left_white_24dp"/>

Related

Unable to Load Images on Android device (v. 4.4.4) from Android Studio Project due to an Inflate Exception

I am faced with the following error which is displayed in Logcat:
01-17 10:31:45.981 317-317/com.example.socialskillstraining E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.socialskillstraining, PID: 317
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.socialskillstraining/com.example.socialskillstraining.MainActivity}: android.view.InflateException: Binary XML file line #36: Error inflating class ImageView
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2429)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493)
at android.app.ActivityThread.access$800(ActivityThread.java:166)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5590)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #36: Error inflating class ImageView
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:720)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:762)
at android.view.LayoutInflater.inflate(LayoutInflater.java:499)
at android.view.LayoutInflater.inflate(LayoutInflater.java:398)
at android.view.LayoutInflater.inflate(LayoutInflater.java:354)
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555)
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161)
at com.example.socialskillstraining.MainActivity.onCreate(MainActivity.java:32)
at android.app.Activity.performCreate(Activity.java:5447)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1094)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2393)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) 
at android.app.ActivityThread.access$800(ActivityThread.java:166) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5590) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x7f07008a
at android.content.res.Resources.getValue(Resources.java:2329)
at androidx.appcompat.widget.ResourcesWrapper.getValue(ResourcesWrapper.java:209)
at androidx.appcompat.widget.ResourceManagerInternal.loadDrawableFromDelegates(ResourceManagerInternal.java:252)
at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:139)
at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:132)
at androidx.appcompat.content.res.AppCompatResources.getDrawable(AppCompatResources.java:104)
at androidx.appcompat.widget.AppCompatImageHelper.loadFromAttributes(AppCompatImageHelper.java:59)
at androidx.appcompat.widget.AppCompatImageView.<init>(AppCompatImageView.java:78)
at androidx.appcompat.widget.AppCompatImageView.<init>(AppCompatImageView.java:68)
at androidx.appcompat.app.AppCompatViewInflater.createImageView(AppCompatViewInflater.java:187)
at androidx.appcompat.app.AppCompatViewInflater.createView(AppCompatViewInflater.java:107)
at androidx.appcompat.app.AppCompatDelegateImpl.createView(AppCompatDelegateImpl.java:1407)
at androidx.appcompat.app.AppCompatDelegateImpl.onCreateView(AppCompatDelegateImpl.java:1457)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:691)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:762) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:499) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:398) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:354) 
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555) 
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161) 
at com.example.socialskillstraining.MainActivity.onCreate(MainActivity.java:32) 
at android.app.Activity.performCreate(Activity.java:5447) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1094) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2393) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) 
at android.app.ActivityThread.access$800(ActivityThread.java:166) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5590) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) 
at dalvik.system.NativeStart.main(Native Method) 
01-17 10:35:01.211 534-534/com.example.socialskillstraining E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.socialskillstraining, PID: 534
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.socialskillstraining/com.example.socialskillstraining.MainActivity}: android.view.InflateException: Binary XML file line #36: Error inflating class ImageView
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2429)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493)
at android.app.ActivityThread.access$800(ActivityThread.java:166)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5590)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #36: Error inflating class ImageView
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:720)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:762)
at android.view.LayoutInflater.inflate(LayoutInflater.java:499)
at android.view.LayoutInflater.inflate(LayoutInflater.java:398)
at android.view.LayoutInflater.inflate(LayoutInflater.java:354)
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555)
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161)
at com.example.socialskillstraining.MainActivity.onCreate(MainActivity.java:32)
at android.app.Activity.performCreate(Activity.java:5447)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1094)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2393)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) 
at android.app.ActivityThread.access$800(ActivityThread.java:166) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5590) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x7f07008a
at android.content.res.Resources.getValue(Resources.java:2329)
at androidx.appcompat.widget.ResourcesWrapper.getValue(ResourcesWrapper.java:209)
at androidx.appcompat.widget.ResourceManagerInternal.loadDrawableFromDelegates(ResourceManagerInternal.java:252)
at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:139)
at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:132)
at androidx.appcompat.content.res.AppCompatResources.getDrawable(AppCompatResources.java:104)
at androidx.appcompat.widget.AppCompatImageHelper.loadFromAttributes(AppCompatImageHelper.java:59)
at androidx.appcompat.widget.AppCompatImageView.<init>(AppCompatImageView.java:78)
at androidx.appcompat.widget.AppCompatImageView.<init>(AppCompatImageView.java:68)
at androidx.appcompat.app.AppCompatViewInflater.createImageView(AppCompatViewInflater.java:187)
at androidx.appcompat.app.AppCompatViewInflater.createView(AppCompatViewInflater.java:107)
at androidx.appcompat.app.AppCompatDelegateImpl.createView(AppCompatDelegateImpl.java:1407)
at androidx.appcompat.app.AppCompatDelegateImpl.onCreateView(AppCompatDelegateImpl.java:1457)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:691)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:762) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:499) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:398) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:354) 
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555) 
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161) 
at com.example.socialskillstraining.MainActivity.onCreate(MainActivity.java:32) 
at android.app.Activity.performCreate(Activity.java:5447) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1094) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2393) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) 
at android.app.ActivityThread.access$800(ActivityThread.java:166) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5590) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) 
at dalvik.system.NativeStart.main(Native Method) 
01-17 10:51:26.963 1198-1198/com.example.socialskillstraining E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.socialskillstraining, PID: 1198
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.socialskillstraining/com.example.socialskillstraining.MainActivity}: android.view.InflateException: Binary XML file line #36: Error inflating class ImageView
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2429)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493)
at android.app.ActivityThread.access$800(ActivityThread.java:166)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5590)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #36: Error inflating class ImageView
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:720)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:762)
at android.view.LayoutInflater.inflate(LayoutInflater.java:499)
at android.view.LayoutInflater.inflate(LayoutInflater.java:398)
at android.view.LayoutInflater.inflate(LayoutInflater.java:354)
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555)
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161)
at com.example.socialskillstraining.MainActivity.onCreate(MainActivity.java:33)
at android.app.Activity.performCreate(Activity.java:5447)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1094)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2393)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) 
at android.app.ActivityThread.access$800(ActivityThread.java:166) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5590) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x7f07008a
at android.content.res.Resources.getValue(Resources.java:2329)
at androidx.appcompat.widget.ResourcesWrapper.getValue(ResourcesWrapper.java:209)
at androidx.appcompat.widget.ResourceManagerInternal.loadDrawableFromDelegates(ResourceManagerInternal.java:252)
at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:139)
at androidx.appcompat.widget.ResourceManagerInternal.getDrawable(ResourceManagerInternal.java:132)
at androidx.appcompat.content.res.AppCompatResources.getDrawable(AppCompatResources.java:104)
at androidx.appcompat.widget.AppCompatImageHelper.loadFromAttributes(AppCompatImageHelper.java:59)
at androidx.appcompat.widget.AppCompatImageView.<init>(AppCompatImageView.java:78)
at androidx.appcompat.widget.AppCompatImageView.<init>(AppCompatImageView.java:68)
at androidx.appcompat.app.AppCompatViewInflater.createImageView(AppCompatViewInflater.java:187)
at androidx.appcompat.app.AppCompatViewInflater.createView(AppCompatViewInflater.java:107)
at androidx.appcompat.app.AppCompatDelegateImpl.createView(AppCompatDelegateImpl.java:1407)
at androidx.appcompat.app.AppCompatDelegateImpl.onCreateView(AppCompatDelegateImpl.java:1457)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:691)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:762) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:499) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:398) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:354) 
at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:555) 
at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161) 
at com.example.socialskillstraining.MainActivity.onCreate(MainActivity.java:33) 
at android.app.Activity.performCreate(Activity.java:5447) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1094) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2393) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) 
at android.app.ActivityThread.access$800(ActivityThread.java:166) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5590) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) 
at dalvik.system.NativeStart.main(Native Method) 
The odd thing is that the images load both on my emulator as well as on another android device (running on v. 9), so the issue seems to be with the old android version. The following is the image view which is causing the above exception:
<ImageView
android:id="#+id/imageView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="125dp"
android:layout_marginTop="65dp"
android:layout_marginEnd="125dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:srcCompat="#drawable/logo" />
The image which I am trying to load (logo) is stored in the drawable folder. I am quite lost as I find it strange how the android version could be impacting the success of loading images into my application.
Any help is appreciated. Thanks in advance!
Solved it. I first uninstalled and reinstalled the application on the device. Then, I imported the images as hdpi files.

android.view.InflateException: Binary XML file line #11: Error inflating class de.ehsun.coloredtimebar.TimelineView

I'm working on a app in which user can reserve a seat. User has to choose a time range for his booking. I wanted a time range picker in which I can customize the time whereas user can only choose time from 07:00 to 19:00. I found a library called colored-time-selector https://github.com/ehsunshine/colored-time-selector this library has everything what I was looking for.
But I'm facing below error on android kitkat 4.4 it works fine on lollipop and above.
XML
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background=""
tools:context=".booking.test">
<de.ehsun.coloredtimebar.TimelinePickerView
android:id="#+id/timelineView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:barColorAvailable="#color/available_time_default_color"
app:barColorHighlight="#color/selector_default_color"
app:barColorNotAvailable="#color/timeline_default_color"
app:barWidth="16dp"
app:fractionLineColor="#color/separatorDark"
app:fractionLineLength="8dp"
app:fractionLineWidth="1dp"
app:fractionPrimaryTextColor="#color/fraction_default_color"
app:fractionSecondaryTextColor="#color/fraction_default_color"
app:fractionTextInterval="2"
app:fractionTextSize="8sp"
app:timeRange="07:00-19:00" />
</android.support.constraint.ConstraintLayout>
Java
public class test extends AppCompatActivity {
TimelinePickerView tl;
#Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_test); //shows error over here
//diamond operator
List<String> list = new ArrayList<>();
list.add("11:00 - 19:15");
list.add("20:00 - 21:00");
tl = (TimelinePickerView) findViewById(R.id.timelineView);
tl.setAvailableTimeRange(list);
//tl.setPickerDrawable(getResources().getDrawable(R.drawable.ic_camera));
}
}
Error
04-16 07:36:18.341 31897-31897/net.cfgvd.bookingE/AndroidRuntime: FATAL EXCEPTION: main
Process: net.cfgvd.booking, PID: 31897
java.lang.RuntimeException: Unable to start activity ComponentInfo{net.cfgvd.booking/net.cfgvd.booking.test}: android.view.InflateException: Binary XML file line #11: Error inflating class de.ehsun.coloredtimebar.TimelinePickerView
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2292)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2350)
at android.app.ActivityThread.access$800(ActivityThread.java:163)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1257)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:157)
at android.app.ActivityThread.main(ActivityThread.java:5335)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1265)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1081)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:132)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #11: Error inflating class de.ehsun.coloredtimebar.TimelinePickerView
at android.view.LayoutInflater.createView(LayoutInflater.java:626)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:702)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:761)
at android.view.LayoutInflater.inflate(LayoutInflater.java:498)
at de.robv.android.xposed.XposedBridge.invokeOriginalMethodNative(Native Method)
at de.robv.android.xposed.XposedBridge.handleHookedMethod(XposedBridge.java:631)
at android.view.LayoutInflater.inflate(Native Method)
at android.view.LayoutInflater.inflate(LayoutInflater.java:398)
at android.view.LayoutInflater.inflate(LayoutInflater.java:354)
at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287)
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139)
at net.aafushh.smoky.booking.test.onCreate(test.java:20)
at android.app.Activity.performCreate(Activity.java:5389)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2256)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2350) 
at android.app.ActivityThread.access$800(ActivityThread.java:163) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1257) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:157) 
at android.app.ActivityThread.main(ActivityThread.java:5335) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1265) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1081) 
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:132) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:600)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:702) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:761) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:498) 
at de.robv.android.xposed.XposedBridge.invokeOriginalMethodNative(Native Method) 
at de.robv.android.xposed.XposedBridge.handleHookedMethod(XposedBridge.java:631) 
at android.view.LayoutInflater.inflate(Native Method) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:398) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:354) 
at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287) 
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139) 
at net.aafushh.smoky.booking.test.onCreate(test.java:20) 
at android.app.Activity.performCreate(Activity.java:5389) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2256) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2350) 
at android.app.ActivityThread.access$800(ActivityThread.java:163) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1257) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:157) 
at android.app.ActivityThread.main(ActivityThread.java:5335) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1265) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1081) 
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:132) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.NoSuchMethodError: android.view.View.<init>
at de.ehsun.coloredtimebar.TimelineView.<init>(TimelineView.kt:15)
at de.ehsun.coloredtimebar.TimelinePickerView.<init>(TimelinePickerView.kt:15)
at de.ehsun.coloredtimebar.TimelinePickerView.<init>(TimelinePickerView.kt:14)
at de.ehsun.coloredtimebar.TimelinePickerView.<init>(TimelinePickerView.kt)
at java.lang.reflect.Constructor.constructNative(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) 
at android.view.LayoutInflater.createView(LayoutInflater.java:600) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:702) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:761) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:498) 
at de.robv.android.xposed.XposedBridge.invokeOriginalMethodNative(Native Method) 
at de.robv.android.xposed.XposedBridge.handleHookedMethod(XposedBridge.java:631) 
at android.view.LayoutInflater.inflate(Native Method) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:398) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:354) 
at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287) 
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139) 
at net.aafushh.smoky.booking.test.onCreate(test.java:20) 
at android.app.Activity.performCreate(Activity.java:5389) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2256) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2350) 
at android.app.ActivityThread.access$800(ActivityThread.java:163) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1257) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:157) 
at android.app.ActivityThread.main(ActivityThread.java:5335) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1265) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1081) 
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:132) 
at dalvik.system.NativeStart.main(Native Method) 
Someone please help me on this issue. thank you
The minimum sdkversion of de.ehsun.coloredtimebar.TimelinePickerView is 19. so it works fine in kitkat and above versions. It will not work in below versions than kitkat.

android.view.InflateException: Binary XML file line #0: Error inflating class android.widget.CheckBox

A few days ago my code was working fine. I'm building and testing on a leimin z4 Android version 4.4.2 sdk 19. All was well. I was also testing on tecno n8s.
Everything was ok until yesterday when I run things my WebView and long click on a CardView are all giving me this errors:
Process: kamble.travelite.com, PID: 27771
android.view.InflateException: Binary XML file line #37: Error inflating class com.android.internal.widget.ActionBarView
at android.view.LayoutInflater.createView(LayoutInflater.java:620)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.createCustomViewInternal(CalligraphyLayoutInflater.java:211)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.access$000(CalligraphyLayoutInflater.java:20)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater$PrivateWrapperFactory2.onCreateView(CalligraphyLayoutInflater.java:302)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:689)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
at com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:3108)
at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:3172)
at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1718)
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3019)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2395)
at android.app.ActivityThread.access$800(ActivityThread.java:151)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321)
at android.os.Handler.dispatchMessage(Handler.java:110)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:5299)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:594)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.createCustomViewInternal(CalligraphyLayoutInflater.java:211) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.access$000(CalligraphyLayoutInflater.java:20) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater$PrivateWrapperFactory2.onCreateView(CalligraphyLayoutInflater.java:302) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:689) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:3108) 
at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:3172) 
at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1718) 
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3019) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2395) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5299) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: android.view.InflateException: Binary XML file line #23: Error inflating class <unknown>
at android.view.LayoutInflater.createView(LayoutInflater.java:620)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:164)
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:669)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:148)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:694)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at com.android.internal.widget.ActionBarView.initTitle(ActionBarView.java:845)
at com.android.internal.widget.ActionBarView.setDisplayOptions(ActionBarView.java:663)
at com.android.internal.widget.ActionBarView.<init>(ActionBarView.java:227)
at java.lang.reflect.Constructor.constructNative(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) 
at android.view.LayoutInflater.createView(LayoutInflater.java:594) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.createCustomViewInternal(CalligraphyLayoutInflater.java:211) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.access$000(CalligraphyLayoutInflater.java:20) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater$PrivateWrapperFactory2.onCreateView(CalligraphyLayoutInflater.java:302) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:689) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:3108) 
at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:3172) 
at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1718) 
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3019) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2395) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5299) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:594)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:164) 
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:669) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:148) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:694) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at com.android.internal.widget.ActionBarView.initTitle(ActionBarView.java:845) 
at com.android.internal.widget.ActionBarView.setDisplayOptions(ActionBarView.java:663) 
at com.android.internal.widget.ActionBarView.<init>(ActionBarView.java:227) 
at java.lang.reflect.Constructor.constructNative(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) 
at android.view.LayoutInflater.createView(LayoutInflater.java:594) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.createCustomViewInternal(CalligraphyLayoutInflater.java:211) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.access$000(CalligraphyLayoutInflater.java:20) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater$PrivateWrapperFactory2.onCreateView(CalligraphyLayoutInflater.java:302) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:689) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:3108) 
at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:3172) 
at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1718) 
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3019) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2395) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5299) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.UnsupportedOperationException: Can't convert to color: type=0x2
at android.content.res.TypedArray.getColor(TypedArray.java:327)
at android.widget.TextView.<init>(TextView.java:695)
at android.widget.TextView.<init>(TextView.java:637)
and also this one
Process: kamble.travelite.com, PID: 27350
java.lang.RuntimeException: Unable to start activity ComponentInfo{kamble.travelite.com/kamble.travelite.com.WebActivity2}: android.view.InflateException: Binary XML file line #0: Error inflating class android.widget.CheckBox
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2338)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2390)
at android.app.ActivityThread.access$800(ActivityThread.java:151)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321)
at android.os.Handler.dispatchMessage(Handler.java:110)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:5299)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #0: Error inflating class android.widget.CheckBox
at android.view.LayoutInflater.createView(LayoutInflater.java:620)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:164)
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:669)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:148)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:694)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
at kamble.travelite.com.WebActivity2.showDialog(WebActivity2.java:138)
at kamble.travelite.com.WebActivity2.onCreate(WebActivity2.java:46)
at android.app.Activity.performCreate(Activity.java:5264)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2302)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2390) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5299) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:594)
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:164) 
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:669) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.onCreateView(CalligraphyLayoutInflater.java:148) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:694) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at uk.co.chrisjenx.calligraphy.CalligraphyLayoutInflater.inflate(CalligraphyLayoutInflater.java:60) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at kamble.travelite.com.WebActivity2.showDialog(WebActivity2.java:138) 
at kamble.travelite.com.WebActivity2.onCreate(WebActivity2.java:46) 
at android.app.Activity.performCreate(Activity.java:5264) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2302) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2390) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5299) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.UnsupportedOperationException: Can't convert to color: type=0x2
at android.content.res.TypedArray.getColor(TypedArray.java:327)
at android.widget.TextView.<init>(TextView.java:695)
at android.widget.Button.<init>(Button.java:107)
at android.widget.CompoundButton.<init>(CompoundButton.java:68)
at android.widget.CheckBox.<init>(CheckBox.java:68)
at android.widget.CheckBox.<init>(CheckBox.java:64)
successively.
<CheckBox
android:id="#+id/checkBox"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="#string/dialog_close" />
This is the xml for the checkbox. The parent is a LinearLayout.
The issue came about because I was using a theme that was not inheriting from Theme.AppCompat. That is why there was that error.For anyone getting a similar error.Check your theme first.Also you can consider using Theme.AppCompat for your apps.

Android Error inflating class com.shamanland.fonticon.FontIconView

I am using Shamanland FontIconView but my Activity can't be started and my app crashes
Steack Trace:
FATAL EXCEPTION: main
Process: com.example.mmido.asfarandroid, PID: 14010
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.mmido.asfarandroid/com.example.mmido.asfarandroid.As
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2385)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2436)
at android.app.ActivityThread.access$800(ActivityThread.java:157)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1374)
at android.os.Handler.dispatchMessage(Handler.java:110)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:5398)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:940)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #15: Error inflating class com.shamanland.fonticon.FontIconView
at android.view.LayoutInflater.createView(LayoutInflater.java:620)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
at android.support.v7.app.AppCompatDelegateImplV7.setContentView(AppCompatDelegateImplV7.java:280)
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:140)
at com.example.mmido.asfarandroid.AsfarApp.PaymentActivity.onCreate(PaymentActivity.java:13)
at android.app.Activity.performCreate(Activity.java:5264)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2349)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2436) 
at android.app.ActivityThread.access$800(ActivityThread.java:157) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1374) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5398) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:940) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:594)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at android.support.v7.app.AppCompatDelegateImplV7.setContentView(AppCompatDelegateImplV7.java:280) 
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:140) 
at com.example.mmido.asfarandroid.AsfarApp.PaymentActivity.onCreate(PaymentActivity.java:13) 
at android.app.Activity.performCreate(Activity.java:5264) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2349) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2436) 
at android.app.ActivityThread.access$800(ActivityThread.java:157) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1374) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5398) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:940) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.IllegalStateException
at com.shamanland.fonticon.FontIconTypefaceHolder.getTypeface(FontIconTypefaceHolder.java:11)
at com.shamanland.fonticon.FontIconView.<init>(FontIconView.java:129)
at java.lang.reflect.Constructor.constructNative(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) 
at android.view.LayoutInflater.createView(LayoutInflater.java:594) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at android.support.v7.app.AppCompatDelegateImplV7.setContentView(AppCompatDelegateImplV7.java:280) 
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:140) 
at com.example.mmido.asfarandroid.AsfarApp.PaymentActivity.onCreate(PaymentActivity.java:13) 
at android.app.Activity.performCreate(Activity.java:5264) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2349) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2436) 
at android.app.ActivityThread.access$800(ActivityThread.java:157) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1374) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5398) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:940) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756) 
at dalvik.system.NativeStart.main(Native Method) 
My Layout:
?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#android:color/white"
android:focusableInTouchMode="true"
android:orientation="vertical">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="#dimen/pf_tittle_header_height"
android:background="#color/pf_gray">
<com.shamanland.fonticon.FontIconView
android:id="#+id/backButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_margin="#dimen/pf_border_space"
android:clickable="true"
android:onClick="onBackPressed"
android:text="#string/icon_left_circled"
android:textColor="#android:color/white"
android:textSize="#dimen/pf_back_icon_txt_size"
app:pressedGlowColor="#color/pf_green"
app:pressedGlowRadius="#dimen/pf_icon_glow_radius" />
Line #15 is this line <com.shamanland.fonticon.FontIconView
i checked String values and dimension used in FontIconView and they are correct .what is the error here please?
Thanks.
I was also facing the same problem day before yesterday in my project, so the solution I found is: Just paste your .ttf file inside the asset folder in your project (if folder is not there just create one inside app->src->main) and initialize the FontIconTypefaceHolder() in your main activity inside onCreate() method. Like as
FontIconTypefaceHolder.init(getAssets(),"icon.ttf");
The constructor throws an IllegalStateException due to:
Caused by: java.lang.IllegalStateException
at com.shamanland.fonticon.FontIconTypefaceHolder.getTypeface(FontIconTypefaceHolder.java:11)
Since this project is open source, put a breakpoint there and debug the issue.

Recyclerview + Picasso outofmemory error

I am facing issue of outofmemory when using recyclerview and picasso.
Picasso.with(context).load(waterSourcesList.get(position).icon).into(holder.ivSourceIcon);
When moving screen home to second screen and second screen to home screen continuously i am getting following error :
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.xyz.android/com.xyz.android.second.SecondActivity}: android.view.InflateException: Binary XML file line #2: Error inflating class <unknown>
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2201)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2250)
at android.app.ActivityThread.access$900(ActivityThread.java:141)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1213)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5072)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:609)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #2: Error inflating class <unknown>
at android.view.LayoutInflater.createView(LayoutInflater.java:623)
at com.android.internal.policy.impl.PhoneLayoutInflater.onCreateView(PhoneLayoutInflater.java:56)
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:672)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:697)
at android.view.LayoutInflater.inflate(LayoutInflater.java:472)
at android.view.LayoutInflater.inflate(LayoutInflater.java:400)
at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
at com.madzialipo.android.boreholeNearMe.SecondActivity.onCreate(SecondActivity.java:70)
at android.app.Activity.performCreate(Activity.java:5249)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2165)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2250) 
at android.app.ActivityThread.access$900(ActivityThread.java:141) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1213) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5072) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:609) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.constructNative(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at android.view.LayoutInflater.createView(LayoutInflater.java:597)
at com.android.internal.policy.impl.PhoneLayoutInflater.onCreateView(PhoneLayoutInflater.java:56) 
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:672) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:697) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:472) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:400) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at com.madzialipo.android.boreholeNearMe.SecondActivity.onCreate(SecondActivity.java:70) 
at android.app.Activity.performCreate(Activity.java:5249) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2165) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2250) 
at android.app.ActivityThread.access$900(ActivityThread.java:141) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1213) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5072) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:609) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.OutOfMemoryError
at android.graphics.BitmapFactory.nativeDecodeAsset(Native Method)
at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:601)
at android.graphics.BitmapFactory.decodeResourceStream(BitmapFactory.java:434)
at android.graphics.drawable.Drawable.createFromResourceStream(Drawable.java:840)
at android.content.res.Resources.createFromResourceStream(Resources.java:2513)
at android.content.res.Resources.loadDrawable(Resources.java:2165)
at android.content.res.Resources.loadDrawable(Resources.java:2072)
at android.content.res.TypedArray.getDrawable(TypedArray.java:602)
at android.view.View.<init>(View.java:3562)
at android.view.ViewGroup.<init>(ViewGroup.java:470)
at android.widget.LinearLayout.<init>(LinearLayout.java:176)
at android.widget.LinearLayout.<init>(LinearLayout.java:172)
at java.lang.reflect.Constructor.constructNative(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) 
at android.view.LayoutInflater.createView(LayoutInflater.java:597) 
at com.android.internal.policy.impl.PhoneLayoutInflater.onCreateView(PhoneLayoutInflater.java:56) 
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:672) 
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:697) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:472) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:400) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at com.madzialipo.android.boreholeNearMe.SecondActivity.onCreate(SecondActivity.java:70) 
at android.app.Activity.performCreate(Activity.java:5249) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2165) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2250) 
at android.app.ActivityThread.access$900(ActivityThread.java:141) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1213) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5072) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515)
It happened with me because i got project from my colleague in which he used heavy size images in background. So, app crashed. I just removed background images and its done.

Categories

Resources