Discussion Forums  >  Audio, Video, Playing, Recording

Replies: 4    Views: 235

pimentazores
Aspiring developer
Profile
Posts: 47
Reg: Mar 26, 2013
Barcelona
8,020
03/24/14 04:16 PM (10 years ago)

CP Stream - Notification Bar

Hi guys!, When I close my app that uses the cp stream plugin, if the audio is still playing, it will open a notification bar on the top of the home screen of my device. This is ok, but App should work normally when opening notification bar to play or pause music, but it crashes. How can I change the app behavior so when I leave the app (pressing back button or home screen button) it will just completely stop and destroy the app? Thanks in advance
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
03/24/14 07:23 PM (10 years ago)
I don't have a project open, but if you're not scared of code, you need to find the command to stop the audio, and add that to the 'on pause' or 'on stop' methods in the cp stream class file. Sorry I can't be more informational… I wrote this in a post before, but for the life of me I can't seem to find it. Cheers! -- Smug
 
pimentazores
Aspiring developer
Profile
Posts: 47
Reg: Mar 26, 2013
Barcelona
8,020
like
03/25/14 03:54 PM (10 years ago)
Thanks Smug, do you happen to know which command to use?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
03/25/14 04:13 PM (10 years ago)
 
pimentazores
Aspiring developer
Profile
Posts: 47
Reg: Mar 26, 2013
Barcelona
8,020
like
03/25/14 04:16 PM (10 years ago)
Thanks again for your help, Smug. Another issue solved. I’ve made the two changes and it really improved sooo much the app’s behavior... and it was so simple! Priceless help, as always, from you. If you ever come to Barcelona I’ll be pleased to invite for a seafood paella ;) All the best, Pedro
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.