Pause background music in Android

There are many examples of suspending background music on the Internet. The most common is to send a broadcast to suspend music according to the suspension instruction. In fact, this method is very unreliable. Why? Because other players don't necessarily register to listen to that broadcast, it doesn't work in most cases.

The following is a reliable way to operate the player state by triggering the media button.

Another way for netizens to realize

Write down the process briefly

The following is to open a thread to cycle to obtain spectrum information. I only post the obtained spectrum information

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>