>
> As Bnet above, i'm trying to write a program whichs detects the
> different states of the phone and mke a different noise in each case.
> There is a problem that i really don't understand!!!!!
> Please someone can take a look at it and try to explain to ma what's
> wrong ?

1. You have created a PhoneStateListener and then have done nothing with
it. Please look at TelephonyManager#listen() in the documentation.

2. You are not cleaning up the MediaPlayer objects you are creating, which
might be bad.

3. You are not unregistering your PhoneStateListener when your activity
closes (e.g., in onDestroy()).

There may be other issues -- those three come to mind for me.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
_The Busy Coder's Guide to Android Development_ Version 2.0 Available!



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to