From 9c70d135196012d5db210be12cc9d866ce683896 Mon Sep 17 00:00:00 2001 From: wenlele Date: Wed, 31 Aug 2022 16:07:57 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=86=E9=A2=91=E5=85=A8=E5=B1=8F=E5=92=8C?= =?UTF-8?q?=E8=83=8C=E6=8A=95=E5=86=B2=E7=AA=81=E9=9C=80=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/videoPlayer/videoPlay.jsx | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx b/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx index 56c42d8..9c1c45f 100644 --- a/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx +++ b/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx @@ -208,13 +208,14 @@ const VideoPlay = ({ operationRef.current = nextOperationState // 全屏状态监听 - screenfull.on('change', () => { - console.log(screenfull); - if (screenfull.isFullscreen && operationRef.current && !operationRef.current['fullScreen'].select) { - changeSelectState('fullScreen') - } - if (!screenfull.isFullscreen && operationRef.current && operationRef.current['fullScreen'].select) { - changeSelectState('fullScreen') + screenfull.on('change', (e) => { + if (e?.path[0]?.id=="vcmp_videoplay") { + if (screenfull.isFullscreen && operationRef.current && !operationRef.current['fullScreen'].select) { + changeSelectState('fullScreen') + } + if (!screenfull.isFullscreen && operationRef.current && operationRef.current['fullScreen'].select) { + changeSelectState('fullScreen') + } } }); // const resize_ = () => {