Video stopped working with iOS 5 SDK

You must Login before you can answer or comment on any questions.

I built a project using the iOS 4.3 SDK and had video working with this code:

var win = Ti.UI.currentWindow;
var vidPlayer = Ti.Media.createVideoPlayer({
    width:'100%',
    height:'100%',
    top:0,
    left:0,
    backgroundColor:'#000000',
    autoplay:true,
    allowsAirPlay:true,
    fullscreen:true,
    url: win.videoLocation
});
win.add(vidPlayer);
 
vidPlayer.addEventListener('fullscreen', function (e)
{
    if (!e.entering)
    {
        Ti.API.info("Done button clicked");
        win.orientationModes = [Ti.UI.PORTRAIT];
        vidPlayer.stop();
        vidPlayer.release();
        win.close();
    }
});
 
function vidComplete()
{
    Ti.API.info("video complete");
    win.orientationModes = [Ti.UI.PORTRAIT];
    vidPlayer.stop();
    vidPlayer.release();    
    win.close();
};
vidPlayer.addEventListener('complete',vidComplete);
I recently switched to iOS 5 and it doesn't work anymore. If I change the project back to 4.3 it works. Any ideas?

— asked 1 year ago by Ronnie Swietek
1 Comment
  • I forgot to mention, I receive no errors in the console

    — commented 1 year ago by Ronnie Swietek

2 Answers

This should help, just posted it. http://developer.appcelerator.com/question/135367/fullscreen-video-player-example-works

Your Answer

Think you can help? Login to answer this question!