mirror of https://github.com/Kylart/KawAnime.git
Put layout how into store and fixed cursor not hiding
This commit is contained in:
parent
970d31715d
commit
8a24560b16
|
@ -48,7 +48,6 @@ export default {
|
|||
},
|
||||
|
||||
data: () => ({
|
||||
show: true,
|
||||
timeoutID: null
|
||||
}),
|
||||
|
||||
|
@ -56,6 +55,17 @@ export default {
|
|||
setTimeout(this.hide, 1500)
|
||||
},
|
||||
|
||||
computed: {
|
||||
show: {
|
||||
get () {
|
||||
return this.$store.getters['streaming/controls'].show
|
||||
},
|
||||
set (bool) {
|
||||
this.$store.commit('streaming/setControl', { name: 'show', value: bool })
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
reveal () {
|
||||
this.show = true
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<template lang="pug">
|
||||
.video-player(
|
||||
@mousemove='onMouseMove',
|
||||
:style='{ cursor: !layoutShow ? "none" : null }'
|
||||
:style='{ cursor: !controls.show ? "none" : null }'
|
||||
)
|
||||
|
||||
wrapper(
|
||||
|
@ -43,8 +43,6 @@ export default {
|
|||
name: '',
|
||||
hasAppendedToHistory: false,
|
||||
|
||||
layoutShow: true,
|
||||
|
||||
propertyMap: {
|
||||
'percent-pos': 'timeline',
|
||||
'media-title': 'name'
|
||||
|
|
|
@ -11,8 +11,6 @@ export default {
|
|||
actOnWindow: this.actOnWindow,
|
||||
mute: this.toggleMute,
|
||||
updateTrack: this.setTrack
|
||||
// show: this.layoutShow = true,
|
||||
// hide: this.layoutShow = false
|
||||
},
|
||||
bind: {
|
||||
subtitles: this.subtitles,
|
||||
|
|
|
@ -4,6 +4,7 @@ export default {
|
|||
link: {},
|
||||
neighbours: null,
|
||||
controls: {
|
||||
show: true,
|
||||
title: '',
|
||||
pause: true,
|
||||
volume: 100,
|
||||
|
|
Loading…
Reference in New Issue