Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request] 希望增加对全局媒体控件的支持 #97

Open
gexgd0419 opened this issue Aug 30, 2022 · 1 comment
Open

[Feature request] 希望增加对全局媒体控件的支持 #97

gexgd0419 opened this issue Aug 30, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@gexgd0419
Copy link

界面内的播放器已经具有了比较完善的播放控件。
但是,既然支持后台播放,用户自然会希望无需切换到浏览器界面也可以控制媒体播放。

目前的版本能够使用耳机的线控、键盘的媒体按钮等实现媒体的播放和暂停。
但是,也就只能做到播放和暂停。并且,使用这种方法暂停播放后,播放按钮的状态并不会正确更新。
至于依靠全局媒体控件来实现切换曲目,目前还是做不到的。

另外,系统的媒体控件浮窗也并不会给出当前播放曲目的信息,例如名称、作者、封面等,只有一个“Kikoeru”的名字。“上一曲”、“下一曲”的按钮是不可用的。
image

DLsite play对此则有较好的支持。

电脑端,系统的媒体控件浮窗会显示曲目的信息以及缩略图,还可以切换上一曲下一曲:
image

手机端,支持的浏览器会在系统的通知栏里显示媒体控件,其中包含了曲目的信息以及缩略图,控件更丰富了,甚至可以直接调整播放进度:
image

具有了这种全局媒体控制的支持后,用户可以使用耳机线控、耳机手势操作、键盘媒体按键等方式,实现播放/暂停、曲目切换等操作,而无需转到浏览器界面。

功能实现方面,可以使用Media Session API

@gexgd0419 gexgd0419 added the enhancement New feature or request label Aug 30, 2022
@umonaca
Copy link
Collaborator

umonaca commented Oct 25, 2022

功能实现方面,可以使用Media Session API
好的。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants