Audio playback stops in iOS when it goes to Standby (unlike Music players, Radio Apps etc).
Hi there!
I need my App to continue playing Audio in the background (for iOS) when it is in StandBy mode (Just like Radio Apps and Music player apps do).
So Far I have done these:
1- Render mode is set to CPU (not Direct/nor GPU).
2- I have included this code in the Main class of my app:
package as3
{
import flash.desktop.NativeApplication;
...
public class Main extends MovieClip
{
public function Main()
{
NativeApplication.nativeApplication.executeInBackground = true;
...
}
}
}
3- in the XML file I have included:
...
<iPhone>
<InfoAdditions>
<![CDATA[
<key>UIBackgroundModes</key>
<array>
<string>audio</string>
</array>
<key>UIDeviceFamily</key>
<array>
<string>1</string>
<string>2</string>
</array>
]]>
</InfoAdditions>
</iPhone>
...
What results have been? Now when I press "HOME" button, the app is minimized and it KEEPS PLAYING AUDIO. geat!!
BUT still when I press the POWER button (means in Standby mode) Audio playback stops (Unlike what I want). What can I do to solve this problem?
I am really grateful for your help in this matter.
Technical details))
Adobe Flash Pro cs6
Air 3.9.0.1210 for ios
testing on Ipad 2/IPhone 5 (iOS 7)
