[AC-1918] iOS 7 Background mode "audio" controller does not work
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Resolved |
Resolution | Cannot Reproduce |
Resolution Date | 2013-10-07T22:46:43.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | Titanium SDK & CLI |
Labels | audio, audioplayer, background, io7, ios6, video, videoplayer |
Reporter | Ezoom Agency |
Assignee | Mostafizur Rahman |
Created | 2013-09-27T14:48:32.000+0000 |
Updated | 2016-03-08T07:40:50.000+0000 |
Description
When your app goes background playing a song, the control center "pause" button won't actually pause it.
Tested with iOS6 and iOS7 device, not sure if it's related do 3.1.3 or argeting iOS7.
add: info.plist
<key>UIBackgroundModes</key><array><string>audio</string></array>
Player code:
var videoPlayer = Ti.Media.createVideoPlayer({
backgroundColor:'#fff',
autoplay:true,
url:'mySong.mp3'
})
Ti.Media.audioSessionMode = Ti.Media.AUDIO_SESSION_MODE_PLAYBACK;
videoPlayer.audioSessionMode = Ti.Media.AUDIO_SESSION_MODE_PLAYBACK;
videoPlayer.play();
"pause" button does not work for videoPlayer, but work for createSound.
Tested on iPhone 5c with iOS 7.0.2 Titanium SDK 3.1.3 Xcode 5
Tested with iPhone 5?iPhone 4?iPad 3?iPad 1? I used this devices in different iOS versions and it happens when using videoPlayer in background.