I've been fiddling with the new DreamService
API for the past few hours, and it's pretty sweet. I do have one question, though.
I'd like to lock the screen orientation to landscape when the DreamService
is shown. The purpose of the DreamService
is to show a number of widescreen photos, and I'd rather not have the black bars at the top and bottom of the screen.
I've tried a number of things, including setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE)
in Java code, and android:screenOrientation="landscape"
in the manifest file, but none have worked.
This makes me wonder: Is it possible to lock the orientation of a DreamService
?
The Android developer team confirmed that this currently isn't possible during a live developer Hangout some time ago.
I believe Google wants DreamServices
to work in both screen orientations, so that's why it isn't possible.