Sound doesn't work when app is reactivated

Hi,
I've developed a small game and deployed it with the packager for iPhone.
Everything works fine until a call interrupts the game. I listen for the events with:
// a call interrupts the app
ativeApplication.nativeApplication.addEventListener(Event.DEACTIVATE, onDeactivate);
// the app is reactivated after the call is finished
NativeApplication.nativeApplication.addEventListener(Event.ACTIVATE, onActivate);
When returning to the app everything works fine except the sound effects are not working anymore.
It seems as if iOS »mutes« the app for the call but forgets to »unmute« it when returning.
Anyone experienced the same? Any solutions to this problem?
I appreciate your help.
Cheers,
Fabian

i'm not so sure it's an iOS problem.  i suspect a coding problem.
to test, create a new app that contains one frame, your sound in the library with a class (eg, S) and add:
var sp:Sprite=new Sprite();
addChild(sp);
with(sp.graphics){
beginFill(0xaa0000);
drawRect(10,10,20,20);
endFill();
var s:S=new S();
sp.addEventListener(MouseEvent.CLICK,f);
function f(e:Event):void{
s.play();
make sure the sound plays when the sprite is clicked, receive a call and then re-activate your app.  if you fail to hear the sound with that code, try:
var sp:Sprite=new Sprite();
addChild(sp);
with(sp.graphics){
beginFill(0xaa0000);
drawRect(10,10,20,20);
endFill();
var s:S=new S();
var sc:SoundChannel;
sp.addEventListener(MouseEvent.CLICK,f);
function f(e:Event):void{
sc=s.play();
var st:SoundTransform=sc.soundTransform;
st.volume=1;
sc.soundTransform=st;

Similar Messages

  • The sound doesn't work in apps viber, magick jack and skype

    when I try to make/answer a call in magic jack, skype or viber the sound doesn't work... i only can hear if I use the speaker mode... What should I do to fix it???

    Could this be an error?
    isapnp: Scanning for PnP cards...
    isapnp: No Plug & Play device found
    And this is what I found regarding my sound card
    HDA Intel 0000:00:14.2: PCI INT A -> GSI 16 (level, low) -> IRQ 16
    HDA Intel 0000:00:14.2: setting latency timer to 64
    input: HDA Digital PCBeep as /devices/pci0000:00/0000:00:14.2/input/input2
    input: HDA ATI SB Mic at Ext Front Jack as /devices/pci0000:00/0000:00:14.2/inpu
    t/input3
    input: HDA ATI SB Mic at Sep UNKNOWN Jack as /devices/pci0000:00/0000:00:14.2/in
    put/input4
    input: HDA ATI SB HP Out at Ext Front Jack as /devices/pci0000:00/0000:00:14.2/i
    nput/input5
    HDA Intel 0000:01:00.1: PCI INT B -> GSI 19 (level, low) -> IRQ 19
    HDA Intel 0000:01:00.1: irq 30 for MSI/MSI-X
    HDA Intel 0000:01:00.1: setting latency timer to 64

  • The sound doesn'e work in apps viber, magick jack and skype

    when I try to make/answer a call in magic jack, skype or viber the sound doesn't work... i only can hear if I use the speaker mode... What should I do to fix it???

    Make sure the Ring/Silent switch isn't showing a red bar or dot.
    You can also try restarting or restoring the iPhone.

  • X220i: sound doesn't work when camera is activated

    Hi all,
    I've a weird problem: my sound works well when I'm listening music, video, etc. whith the speakers or an headphone.
    But when I activate the camera (for Skype or Google Hangout), the sound stops to work (while the video image works well).
    When I try to manage the sound (by making the sound test during a videoconference), I got this error message (sorry, it's in French, it means "Impossible to read the test tone"):
    Do you have any idea where the problem comes from?
    Thanks in advance.

    Hi, djiwai91
    If you haven't already, I would recommend trying to update all your drivers and your BIOS to see if that helps. All updates for your system can be found here. After downloading and installing them, test the camera again and see if there are any changes.
    Best of luck,
    Adam
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution!" This will help the rest of the community with similar issues identify the verified solution and benefit from it.

  • Sound doesn't work when two user accounts open?

    I noticed that when I have 2 different user accounts open, the sound only works in one of them. Why is this?

    The iMac is only designed to have one active user at a time, so there's sound only for the account in use.
    Hope this helps

  • Sound doesn't work when I plug in my monitor to HDMI port

    I have a new HP Envy15laptop and an older AcerAC2016W with VGA connection.  I purchased a vga to hdmi adapte cable.  When I plug in my monitor, the sound shuts down.  If I unplug the monitor the laptop speakers work fine.

    Hi,l I don't know which VGA to HDMI cable you are talking about but VGA does not carry sound and your machine may think it use HDMI sound therefore it shuts down sound with HDMI, if you wish to use sound from your computer you need to disable HDMI sound: Right click speakers icon > Select Play back devicesSelect use internal sound  and disable HDMI sound (if it was there) You have to enable it when use pure HDMI (ie from HDMI to HDMI TV for example) Regards.

  • My ipad 2s sound is not working when I have headphones in.

    I've had the Ipad 2 for about two years now and my sound doesn't work when I have headphones in. I mean it works but I have to turn the sound up all the way and it sounds like it would be on the lowest sound mark. Is that confusing. I thought it was my headphones at first and it didn't really bother me because I didn't use headphones a lot. I had the same headphone for about a year which is why I thought they were the problem, but a couple of months ago I got some new, really good pair of headphones and they have the same problem. If I am watching youtube without my headphones and I turn it up all the way I can still hear it if I walk upstairs, but if I put headphones in and turn it up all the way I can barely hear the sound. I know it is not the headphones because they work perfectly in my phone. Is it something wrong with the headphone jack and can I get it fixed at apple.

    Reset iPad
    Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
    Note: Data will not be affected.

  • Macbook pro buzzing, sound doesn't work, disk is falsely full...

    My 15 inch macbook pro has started buzzing a lot lately at random times.  I've had it since 2009, but it's a 2008 model, and I don't know if it's just getting old and telling me that it's going to die soon, or if there's something I can do about it. 
    It also has other problems, like the sound doesn't work when I start it up (the volume icon is greyed out), and doesn't work again until I've restarted it twice. 
    Also, when I have programs open, it'll tell me that my disk is full and I only have a few mb of disk space left even if I had many GB available before I opened the programs.  I tried fixing this on my own by not having multiple programs open at once, but the disk space won't come back until I restart the computer.  It only started doing this a few months ago, and I don't know why.
    I used to keep it on all the time and just let it sleep, but I've been shutting it down every day now, and I have the same problems.  I don't know what's happening, if it's my fault, or if my computer is just dying, but I need it for animation school and professional photography so if possible I want a heads up if it's about to crash on me.
    Thank you.

    This worked for me
    Reboot the Mac and as soon as you hear the boot chime, hold down the Command+Option+P+R keys together
    When you hear the boot sound again, the PRAM has been reset so let the Mac boot again as usual
    At this point your Mac should boot again as usual and no longer have the black display, loading OS X as usual.

  • With my i phone 4 , the Push notifications doesn't work for apps like (fb viber , whatsapp etc ) it only works for the official apps like message  even when im using the phone, has  this probleme with the iOs 6.0.1 and also with the iOs 6.1

    With my i phone 4 , the Push notifications doesn't work for apps like (fb viber , whatsapp etc ) it only works for the official apps like message  even when im using the phone, has  this probleme with the iOs 6.0.1 and also with the iOs 6.1

    This isn't an issue. Notice the screen prior to the one that shows usage has an iCloud section and a Manage Storage button. For this button to activate ios needs to download a few kb from icloud. Switching back to this screen forces ios to download those few kb.

  • I have some problem with my computer because when i turn it up, the screen turns in a blue colour and the sound doesn't work and in this way i can't hear anything

    i have some problem with my computer because when i turn it up, the screen turns in a blue colour and the sound doesn't work and in this way i can't hear anything

    Will u help me or not?

  • In my wife's window, the sound works, when I switch over to my window the sound doesn't work.  I noticed the problem when I went to a YouTube video.  How do I correct this?

    In my wife's window, the sound works, when I switch over to my window the sound doesn't work.  I noticed the problem when I went to a YouTube video.  How do I correct this?

    Hello Kiira Doon,
    The troubleshooting steps detailed below may help get your iPhone's display to function.
    Toggle the ringer switch to see if the unit vibrates. If it does, it could be that iPhone is getting power, but is not displaying any image.
    Try turning iPhone off and then on again.
    While connected to the iPhone charger, try to reset the iPhone.
    If the low-battery screen appears, charge the iPhone.
    My issue is still not resolved. What do I do next?Contact Apple Support.
    iPhone: Hardware troubleshooting
    http://support.apple.com/kb/TS2802
    Cheers,
    Allen

  • HT1338 when i open youtube in safari, the sound doesn't work? This started happening when i downloaded mountain lion.

    Since downloading Mountain Lion, when I open youtube in Safari, then sound doesn't work. Also I started receiving dupolicete email

    Try A and B
    (A) Restart iPad
    1. Hold down the Sleep/Wake button until the red slider appears.
    2. Drag the slider to turn off iPad.
    3. Turn iPad back on, hold down the Sleep/Wake until the Apple logo appears
    (B) Reset iPad
    Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
    Note: Data will not be affected.

  • I'm having problems with facebook notifications.  The sound doesn't work but shows up in banner.  Any suggestions?  I've tried everything but restoring.  Is it a phone problem or an app problem?

    I am having a problem with facebook notifications.  The sound doesn't work but appears as a banner.  I've tried everything but restoring the phone.  Is this a phone problem or an app problem?  Has anybody experienced this problem and were they able to correct it? 

    1) This is because of software version 1.1. See this
    thread for some options as to how to go back to 1.0,
    which will correct the problem...
    http://discussions.apple.com/thread.jspa?threadID=3754
    59&tstart=0
    2) This tends to happen after videos. Give the iPod a
    minute or two to readjust. It should now be more
    accurate.
    3) This?
    iPod shows a folder icon with exclamation
    point
    4) Restore the iPod
    5) Try these...
    iPod Only Shows An Apple Logo and Will Not Start
    Up
    iPod Only Shows An Apple Logo
    I think 3,4, and 5 are related. Try the options I
    posted for each one.
    btabz
    I just noticed that one of the restore methods you posted was to put it into Disk Mode First rather than just use the resstore straight off, I Have tried that and seems to have solved the problem, If it has thank you. previously I have only tried just restoring it skipping this extra step. Hope my iPod stays healthy, if it doesnt its a warrenty job me thinks any way thanks again

  • Purchased tab in "App Store" app doesn't work when AppleID is not an email address.

    After updated my iPhone and iPad to iOS 6 (both 6.0&6.0.1), Purchased tab in "App Store" app doesn't work when AppleID is not an email address. This happened since 6.0 and I hope that it will be fixed in6.0.1 but it doesn't.
    When I tap at Purchased tab in iPad App Store or Purchased bar in Updates tab in iPhone App Store, it just hang on "Loading...", but when I changed to other AppleID, it works. Apparently, my AppleID is not an email address but the other AppleID is an email address.
    Not sure where to send my feedback to Apple about this issue.

    http://www.apple.com/contact/feedback.html

  • My iphone 3g sound doesn't work but goes on and off when i'm using headset,

    my iphone 3g sound doesn't work but when i plug in headset, the headset sound goes on and off. I think the speaker has a problem or touches but why does the headset not work but goes off randomly?Pls help me out

    my iphone 3g sound doesn't work but when i plug in headset, the headset sound goes on and off. I think the speaker has a problem or touches but why does the headset not work but goes off randomly?Pls help me out

Maybe you are looking for