mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-28 10:31:20 -08:00
优化移动端UI
This commit is contained in:
1 parent
beea013daf
commit
7b3913e318
13 files changed
+96
-55
No files matched your search
@@ -21,7 +21,7 @@ export default class Hotkey {
|
||||
});
|
||||
|
||||
this.add(37, () => {
|
||||
player.seek = player.currentTime - 5;
|
||||
player.backward = 5;
|
||||
});
|
||||
|
||||
this.add(38, () => {
|
||||
@@ -29,14 +29,14 @@ export default class Hotkey {
|
||||
});
|
||||
|
||||
this.add(39, () => {
|
||||
player.seek = player.currentTime + 5;
|
||||
player.forward = 5;
|
||||
});
|
||||
|
||||
this.add(40, () => {
|
||||
player.volume -= 0.1;
|
||||
});
|
||||
|
||||
proxy(window, 'keydown', event => {
|
||||
proxy(window, 'keydown', (event) => {
|
||||
if (art.isFocus) {
|
||||
const tag = document.activeElement.tagName.toUpperCase();
|
||||
const editable = document.activeElement.getAttribute('contenteditable');
|
||||
@@ -44,7 +44,7 @@ export default class Hotkey {
|
||||
const events = this.keys[event.keyCode];
|
||||
if (events) {
|
||||
event.preventDefault();
|
||||
events.forEach(fn => fn());
|
||||
events.forEach((fn) => fn());
|
||||
art.emit('hotkey', event);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user