I'm getting the "No Class Def Found Exception" for the ToolBar in some kitkat devices like Samsung, ALTP etc. As per the below link(bug reported to google)
https://code.google.com/p/android/issues/detail?id=78377 #138 - asking the app to use old library classes, if the latest library is not supported is the only solution. I added these lines in my proguard-rules.pro:
to fix this issue.
# Allow obfuscation of android.support.v7.internal.view.menu.**
# to avoid problem on Samsung 4.2.2 devices with appcompat v21
# see https://code.google.com/p/android/issues/detail?id=78377
-keep class !android.support.v7.internal.view.menu.**,android.support.** {*;}
` I have fee in the xml format and proguard was not able to identify these classes,so added the below line too:
-keepclassmembers class * { *;}`
these are the only 2 changes i added extra. But after enabling proguard, my app performance is drastically reduced. It's taking lot of time to load pages and videos. This was not the case earlier. What might be the reason for this and how can I fix this issue. Is there any alternative for solving "NoClassDefFound Error"
.
Thanks in Advance..