Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Posts: 237
Registered: ‎11-24-2012
My Device: Blackberry 10 Dev Alpha
My Carrier: Telkomsel

Change orientation to landscape on Media Player Cards

Hi I use invoke manager to use media player to open video file. I want to change screen orientation to landscape when media player card opened (full screen) and lock it to landscape, when back from card then orientation change to portrait again and lock to portrait. So the landscape orientation only when video play on media player cards How to do this? Thanks

All Replies
Posts: 30
Registered: ‎02-05-2013
My Device: 9860
My Carrier: Vodafone

Re: Change orientation to landscape on Media Player Cards



I would like to know if someone have tried this? If so how we can achieve this?



Posts: 150
Registered: ‎10-19-2010
My Device: Not Specified
My Carrier: Rogers

Re: Change orientation to landscape on Media Player Cards

Hi Kaz!


There currently isn’t a way to specify an orientation of the native media players through invoke, but they should match the orientation of the app that launched it.  In other words, it may be possible to rotate your app, invoke, rotate back in that order to achieve what you want.  I will preface that with the note that I haven't tried it myself, but hopefully it works Smiley Happy



Posts: 230
Registered: ‎01-12-2013
My Device: z30
My Carrier: Mobile Vikings

Re: Change orientation to landscape on Media Player Cards

If the user want to view the movie in landscape, can't he just rotate the device then? I think it's up to the user to decide what he wants...


If you really want to do this, you can have a look if it's possible to change the orientation of your app before invoking the mediaplayer like BVP said.


OrientationSupport *support = OrientationSupport::instance();


 I don't know if it's possible to catch an onCompleted event or something like that of the mediaplayer. Or maybe after the mediaplayer is invoked you can do something like


OrientationSupport *support = OrientationSupport::instance();



More about that topic over here:


BB10-OAuth: GitHub