views:

47

answers:

1

I have some pretty simple Soundboard applications on the Android Market that work flawless on an LG Ally, the Motorola Droid, and the Nexus One, but I recently received an e-mail from a user with the Motorola DroidX claiming that most of the sounds do not work. I've exchanged a few e-mails with him. He claims the Soundboard is the only application running, and he's double checked to make sure that the Media Volume wasn't set to minimum. I'm kind of stumped as to why it would just fine on other phones, but not the DroidX. I really don't have access to one either to play around with. The application isn't doing anything cosmic to play the sounds. Below is a code snippet. Any insights into what might be causing the hang up are greatly appreciated.

public void play(Sample sample) {
  Log.v(TAG, "Playing: " + getString(sample.getButtonTextResId()) + " ("
    + sample.getSoundResId() + ")");

  if (mPlayer != null) {
   mPlayer.stop();
   mPlayer.release();
  }

  MediaPlayer player = MediaPlayer.create(this, sample.getSoundResId());
  mPlayer = player;

  if (player != null) {
   player.setVolume(1.0f, 1.0f);

   player.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {

    @Override
    public void onCompletion(MediaPlayer mp) {
     mp.release();
     mPlayer = null;
    }
   });

   player.start();
  }
 }
A: 

The user resolved this by uninstalling my application and reinstalling it. Not sure why that would fix the issue. If anyone can shed some light, great.

Steven Packard