Reputation: 1046
Yesterday I got my hands on a Galaxy Nexus and to my surprise the background of my app didn't show at all. Everything was there and the app itself worked fine, just that there was no background and since I disabled Androids background smearing appeared.
As testing devices I can access a Galaxy S4, a Motorola G and an LG Tablet, on all devices my app works flawless and a background is shown. I tested several devices with different resolutions on a emulator and they work perfect as well.
Right now I don't distinguish between different layouts, thats what I want to do later. My seperate drawable-xxxx folders are all empty and everything is in the drawable folder.
I set the background in the xml file like that:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/ss0_background"
android:gravity="fill_horizontal"
android:orientation="vertical" >
this is my custom custom theme in the styles.xml file:
<style name="noAnimTheme" parent="android:Theme.NoTitleBar.Fullscreen">
<item name="android:windowAnimationStyle">@null</item>
<item name="android:windowBackground">@null</item>
<item name="android:soundEffectsEnabled">false</item>
</style>
here i disabled androids own background (read somewhere that it is better that way if you have your own background)
and this is part of my manifest file where I use the custom theme:
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/noAnimTheme"
Like I said I never encountered such a problem in the emulators, even when I emulated a Galaxy Nexus, I wouldn't even know where to start to debug this problem.
Thanks in advance for any help!
Upvotes: 0
Views: 375
Reputation: 21
We had a similar issue where the background wasn't showing on the Galaxy Nexus (specifically, the i515), but it was on every other device we tested it on (and all the emulators).
Try putting images in each of the drawable resolution folders: ours didn't work until there was one in drawable-xxhdpi. For some reason the actual device wasn't finding the versions in drawable, drawable-mdpi, or even drawable-xhdpi.
I don't have enough information to call it a bug with the phone, but it was clearly violating expected Android drawable selection behavior.
Upvotes: 1