I see warning message in LogCat saying:
ResourceType: Attempt to retrieve bag 0x7f080015 which is invalid or in a cycle.
The warning message repeats 50+ times which is really annoying. What does it mean? And how do I make it go away?
The reason is that the project has a style defined under "values-fr" but no counterpart under the default values folder.
I was getting that message because I was using the following method to override my styles for different API levels:
<style name="ToolBar" parent="ToolBar.Base"/>
<style name="ToolBar.Base">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">?actionBarSize</item>
<item name="android:background">@color/primary</item>
</style>
And then adding
<style name="ToolBar" parent="ToolBar.Base">
<item name="android:elevation">4dp</item>
</style>
in my v21/styles file. It's the period between ToolBar and Base that's causing the problem. Replace that with an underscore or a different name with no period and you should be fine. For more on why, read what Android has to say about Style and Theme Inheritance.
Anyway, I changed ToolBar.Base
to ToolBar_Base
, and no more error messages.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With