Skip to content

Commit 6bcbea0

Browse files
committed
fix(Cameras): disable picture in picture
Signed-off-by: Pedro Lamas <[email protected]>
1 parent 8a3f961 commit 6bcbea0

File tree

7 files changed

+18
-5
lines changed

7 files changed

+18
-5
lines changed

src/components/widgets/camera/services/DeviceCamera.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
<video
33
ref="streamingElement"
44
autoplay
5+
disablePictureInPicture
6+
playsinline
57
muted
68
:style="cameraStyle"
79
@play="updateStatus('connected')"

src/components/widgets/camera/services/HlsstreamCamera.vue

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22
<video
33
ref="streamingElement"
44
autoplay
5+
disablePictureInPicture
6+
playsinline
57
muted
6-
:crossorigin="crossorigin"
78
:style="cameraStyle"
9+
:crossorigin="crossorigin"
810
@play="updateStatus('connected')"
911
@error="updateStatus('error')"
1012
/>
@@ -45,8 +47,10 @@ export default class HlsstreamCamera extends Mixins(CameraMixin) {
4547
this.hls.on(Hls.Events.MEDIA_ATTACHED, () => {
4648
this.cameraVideo.play()
4749
})
48-
this.hls.on(Hls.Events.ERROR, () => {
49-
this.updateStatus('error')
50+
this.hls.on(Hls.Events.ERROR, (_, data) => {
51+
if (data.fatal) {
52+
this.updateStatus('error')
53+
}
5054
})
5155
} else if (this.cameraVideo.canPlayType('application/vnd.apple.mpegurl')) {
5256
this.cameraVideo.src = url

src/components/widgets/camera/services/IpstreamCamera.vue

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
<template>
22
<video
33
ref="streamingElement"
4-
:src="cameraVideoSource"
54
autoplay
5+
disablePictureInPicture
6+
playsinline
67
muted
7-
:crossorigin="crossorigin"
88
:style="cameraStyle"
9+
:crossorigin="crossorigin"
10+
:src="cameraVideoSource"
911
@play="updateStatus('connected')"
1012
@error="updateStatus('error')"
1113
/>

src/components/widgets/camera/services/WebrtcCamerastreamerCamera.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<video
33
ref="streamingElement"
44
autoplay
5+
disablePictureInPicture
56
playsinline
67
muted
78
:style="cameraStyle"

src/components/widgets/camera/services/WebrtcGo2RtcCamera.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<video
33
ref="streamingElement"
44
autoplay
5+
disablePictureInPicture
56
playsinline
67
muted
78
:style="cameraStyle"

src/components/widgets/camera/services/WebrtcMediamtxCamera.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<video
33
ref="streamingElement"
44
autoplay
5+
disablePictureInPicture
56
playsinline
67
muted
78
:style="cameraStyle"

src/components/widgets/filesystem/FilePreviewDialog.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
<video
1414
v-if="isVideo"
1515
controls
16+
disablePictureInPicture
17+
playsinline
1618
>
1719
<source
1820
:src="src"

0 commit comments

Comments
 (0)