2

My app has been working well (on most phones) until recently when the samsung s3 was updated to Jelly Bean. The screen looks like this: -

Screenshot

It works fine on an S3 using ICS and on most other phones (including other samsung phones).

Any ideas what is different about the S3 that would cause such a problem on Jelly Bean?

Here is the debug info thanks to Edward's App

Debug Info

Ash McConnell
  • 1,340
  • 1
  • 17
  • 28
  • Looks good. Hint: turn your device sideways so that the lines don't run off the right edge. (I'll get around to a better layout someday.) – Edward Falk Dec 03 '12 at 16:37

2 Answers2

1

This sounds similar to my question of earlier this year: Android Samsung S I9000 screen size and density issues

In my case, it had something to do with the Samsung "pentile" display. This technology gave Samsung a higher effective screen resolution. After updating to Jellybean, the devices started reporting the higher screen resolution, fooling some software into thinking it had a much smaller physical size than it actually had. I found out about the bug when customers started complaining that my app no longer fit on the screen. I had to re-tune my font sizes to make it all work again.

I wound up writing a small app that just displays the screen metrics and gives an idea of which resource files have been selected. I find that just running this app and looking at the screen can help immensely when debugging resource issues:

https://play.google.com/store/apps/details?id=org.efalk.showresources

Community
  • 1
  • 1
Edward Falk
  • 9,991
  • 11
  • 77
  • 112
  • Thanks Edward, going to get one of the users who reported the problem to try it out and hopefully it will help! By the way I am using libgdx for the app (a live wallpaper) – Ash McConnell Dec 02 '12 at 22:08
  • It seems to be producing the expected width/height, does the density have to be taken into account too? – Ash McConnell Dec 03 '12 at 10:51
  • Your physical dimensions are 720x1024 but your pixel density is 2.0 (2x baseline), so the "device independent pixels" are 360x512. The last line on the display is "smallest width" which shows that if you had a "drawable-sw320/" directory, it would be used while a "drawable-sw400/" directory would not. On the other hand, if you were storing drawables in "drawable-Xdpi" (more likely), "drawable-xhdpi/" would be chosen in preference to the others. Now give some thought to where your background drawable has been stored. Are you using "drawable-nodpi/" by any chance? – Edward Falk Dec 03 '12 at 16:42
  • Hi Edward, The problem isn't the size of the assets, but the size of the GLSurface (although I do think the size of the assets is probably a problem too!) – Ash McConnell Dec 05 '12 at 10:30
  • Ahhh; can't help you there; dunno anything about GL. – Edward Falk Dec 05 '12 at 16:35
1

Finally found the answer. My manifest had: -

<supports-screens
    android:anyDensity="false"
    android:largeScreens="true"
    android:normalScreens="true"
    android:smallScreens="true"
    >
</supports-screens>

I changed it to: -

<supports-screens
    android:anyDensity="true"
    android:largeScreens="true"
    android:normalScreens="true"
    android:smallScreens="true"
    android:xlargeScreens="true"
    >
</supports-screens>

Works fine now :)

Ash McConnell
  • 1,340
  • 1
  • 17
  • 28