Skip to content

Commit

Permalink
🐛 #139
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidZhang73 committed Mar 6, 2022
1 parent 25b4f0e commit e758335
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
10 changes: 6 additions & 4 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -119,14 +119,16 @@ const q = useQuasar()
q.dark.set('auto')
const useV2 = computed(() => {
console.log('Video Decoder: ', preferenceStore.decoder)
let ret
if (preferenceStore.decoder === 'v1') {
return false
ret = false
} else if (preferenceStore.decoder === 'v2') {
return true
ret = true
} else {
return !!window.VideoDecoder
ret = !!window.VideoDecoder
}
console.log('Video Decoder:', ret ? 'V2' : 'V1')
return ret
})
const progress = computed(() => {
Expand Down
2 changes: 1 addition & 1 deletion src/pages/annotation/CanvasPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -958,7 +958,7 @@ const getTouchLocation = event => {
let currentTarget = canvas.value
let top = 0
let left = 0
while (currentTarget !== undefined) {
while (currentTarget) {
top += currentTarget.offsetTop
left += currentTarget.offsetLeft
currentTarget = currentTarget.offsetParent
Expand Down
2 changes: 1 addition & 1 deletion src/pages/annotation/ControlPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@
label="Grayscale"
></q-toggle>
<q-toggle
v-if="annotationStore.mode !== 'action'"
v-if="!q.platform.has.touch && annotationStore.mode !== 'action'"
v-model="preferenceStore.showPopup"
label="Show popup"
></q-toggle>
Expand Down
5 changes: 3 additions & 2 deletions src/pages/annotation/components/TableBase.vue
Original file line number Diff line number Diff line change
Expand Up @@ -249,8 +249,9 @@ const handleClearAll = () => {
}
const currentInstance = getCurrentInstance()
const focusLast = () => {
if (currentInstance.ctx.$refs.select) {
currentInstance.ctx.$refs.select.at(-1).showPopup()
const selectList = currentInstance.ctx.$refs.select
if (selectList) {
selectList[selectList.length - 1].showPopup()
}
}
defineExpose({
Expand Down

0 comments on commit e758335

Please sign in to comment.