Here is the rough idea of my files. I inherited a bunch of code that uses the public.xml
file to map ids
to themes
. This code throws the error:
Error:(40, 24) Integer types not allowed (at 'theme' with value '0x7f09007a')
However, when I replace the android:theme="0x7f09007a"
with android:theme="@style/myCoolTheme
everything works. I need to be able to use these ids
since so much more of the code I inherited uses them. Am I missing something to make the manifest file use the id mapping in public.xml?
app/src/main/res/AndroidManifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest ...
<application
android:theme="0x7f09007a"
...
</application>
</manifest>
app/src/main/res/values/public.xml
<?xml version="1.0" encoding="utf-8"?>
<resources>
<public type="style" name="myCoolTheme" id="0x7f09007a" />
...
</resources>
app/src/main/res/values/style.xml
<resources>
<style name="AppTheme"
...
</style>
<style name="myCoolTheme" parent="@style/AppTheme" />
</resources>