Android 媒体播放器停止()方法在三星手机中不起作用
我已经在我的声音应用程序中实现了媒体播放器功能 它可以在所有设备上正常工作,而不是在三星手机上。当我点击停止按钮时,播放器会继续播放声音。这是我的停止按钮代码Android 媒体播放器停止()方法在三星手机中不起作用,android,android-mediaplayer,Android,Android Mediaplayer,我已经在我的声音应用程序中实现了媒体播放器功能 它可以在所有设备上正常工作,而不是在三星手机上。当我点击停止按钮时,播放器会继续播放声音。这是我的停止按钮代码 if (mState.equals(State.Playing)) { mMediaPlayer.stop(); mState = State.Paused; if (mState == State.Playing)
if (mState.equals(State.Playing)) {
mMediaPlayer.stop();
mState = State.Paused;
if (mState == State.Playing)
mContentView
.setImageViewResource(R.id.playPauseButton,
R.drawable.pause_icon);
else
mContentView.setImageViewResource(
R.id.playPauseButton, R.drawable.play_icon);
mBuilder.setContent(mContentView);
mNotification = mBuilder.build();
mNotificationManager.notify(NOTIFICATION_ID,
mNotification);}