mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-08-14 23:57:27 +00:00
parent
a379dbb34f
commit
34bfd696c9
1 changed files with 41 additions and 1 deletions
|
@ -81,7 +81,7 @@ export default {
|
|||
.then(hotkeys => {
|
||||
this.hotkeys = hotkeys;
|
||||
var self = this;
|
||||
hotkeys("f,m,j,k,l,c,space,up,down,left,right", function(e, handler) {
|
||||
hotkeys("f,m,j,k,l,c,space,up,down,left,right,0,1,2,3,4,5,6,7,8,9", function(e, handler) {
|
||||
const videoEl = self.$refs.videoEl;
|
||||
switch (handler.key) {
|
||||
case "f":
|
||||
|
@ -126,6 +126,46 @@ export default {
|
|||
videoEl.currentTime = videoEl.currentTime + 5;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "0":
|
||||
videoEl.currentTime = 0;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "1":
|
||||
videoEl.currentTime = videoEl.duration * 0.1;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "2":
|
||||
videoEl.currentTime = videoEl.duration * 0.2;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "3":
|
||||
videoEl.currentTime = videoEl.duration * 0.3;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "4":
|
||||
videoEl.currentTime = videoEl.duration * 0.4;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "5":
|
||||
videoEl.currentTime = videoEl.duration * 0.5;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "6":
|
||||
videoEl.currentTime = videoEl.duration * 0.6;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "7":
|
||||
videoEl.currentTime = videoEl.duration * 0.7;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "8":
|
||||
videoEl.currentTime = videoEl.duration * 0.8;
|
||||
e.preventDefault();
|
||||
break;
|
||||
case "9":
|
||||
videoEl.currentTime = videoEl.duration * 0.9;
|
||||
e.preventDefault();
|
||||
break;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue