Make sure screen.orientation is always valid

If the orientation has not been set by the extension yet, query it
synchronously.
Merge pull request #1488 from kenchris/sync

Make sure screen.orientation is always valid