blackberry/SDL — pull request #30 by jgranick (2012-09-04 16:52:55+00:00)
Title: Added initial support for portrait orientation

SDL for BlackBerry has been designed for landscape only. We really need support for portrait orientation as well.

I had tried to add formal support for portrait orientation in the past, but somehow it never worked properly. Today I found a way to make it happen. This may not be the most elegant solution, but it's a start. At the right places, I have added a check for an environment variable called "FORCE_PORTRAIT", where it switches width and height values in order to render properly.

Both landscape and portrait are now working properly, so long as I specify the "FORCE_PORTRAIT" environment variable in my bar-descriptor.xml when needed.

This is important for a game we are bringing over today, but will also be vital for BlackBerry 10 smartphones, since portrait orientation will likely become much more common, particularly for a 720 x 720 device.