pull/34/head
kunfei 5 years ago
parent 3abdcb83dc
commit 24f6c66b15
  1. 3
      app/src/main/java/io/legado/app/service/BaseReadAloudService.kt

@ -291,7 +291,7 @@ abstract class BaseReadAloudService : BaseService(),
return request == AudioManager.AUDIOFOCUS_REQUEST_GRANTED return request == AudioManager.AUDIOFOCUS_REQUEST_GRANTED
} }
fun upMediaSessionPlaybackState(state: Int) { private fun upMediaSessionPlaybackState(state: Int) {
mediaSessionCompat?.setPlaybackState( mediaSessionCompat?.setPlaybackState(
PlaybackStateCompat.Builder() PlaybackStateCompat.Builder()
.setActions(MediaHelp.MEDIA_SESSION_ACTIONS) .setActions(MediaHelp.MEDIA_SESSION_ACTIONS)
@ -300,7 +300,6 @@ abstract class BaseReadAloudService : BaseService(),
) )
} }
/** /**
* 初始化MediaSession, 注册多媒体按钮 * 初始化MediaSession, 注册多媒体按钮
*/ */

Loading…
Cancel
Save