1

My API 14+ portrait-only Android app displays one GridLayout inside a vertical ScrollView. As soon as Testdroid's crawler presses just one button (or whatever its first event is doing) on the Samsung Galaxy Tab 3 10.1, the screen rotates 90 degrees. Worse still, rather than just cropping, everything that showed up (correctly) in portrait seems to be getting stretched into the rotated screen, thus making it look awful.

The manifest contains

android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize"

In addition to the XML I have seemingly tried every single programmatic portrait-forcing technique posted here (there are plenty!), all to no avail. In case an Android expert might immediately recognize what needs to be done---I'm still pretty much a newbie---here are a couple of screenshots:

immediately after launch

enter image description here

There has to be a way to fix this. Does anyone know how?

mathematrucker
  • 166
  • 1
  • 9
  • I've seen similar behavior on a ZTE V55. Despite everything being set to `sensorLandscape`, it would briefly display in portrait when the device was rotated. In your case, does it immediately switch back to the intended orientation, or does it remain in landscape? – Kevin Krumwiede May 01 '15 at 18:02
  • Are you **absolutely sure** nothing at http://stackoverflow.com/questions/4885620/force-portrait-orientation-mode or http://stackoverflow.com/questions/6745797/how-to-set-entire-application-in-portrait-mode-only solves your problem? – Chris Stratton May 01 '15 at 18:03
  • @Chris Stratton nothing in those two references solves the problem. I'm guessing it must have something to do with the Galaxy Tab 3 10.1 being a landscape tablet. Today I noticed it displays the bad screen at launch when all code specifying orientation is removed. If this behavior is limited to no more than a few devices I'll just exclude them in Google Play and forget about trying to debug. – mathematrucker May 02 '15 at 05:33
  • @Kevin Krumwiede as far as I can tell the bad screen persists once it has gone bad. Note that I am not testing the physical device locally, but rather through Testdroid. – mathematrucker May 02 '15 at 05:39
  • Just moments ago I opened up my app on the Galaxy Tab 3 10.1 at TestObject.com and it runs fine there. So this orientation issue evidently originates with Testdroid. – mathematrucker May 07 '15 at 00:23

0 Answers0