From b9dc7e796741f1fa478aa27ca64977b4ef4272bc Mon Sep 17 00:00:00 2001 From: "DESKTOP-9FJNTIC\\gyb" <121287102@qq.com> Date: Sat, 26 Jul 2025 18:11:18 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=BB=E4=B8=AD=E7=94=BB=E9=80=BB=E8=BE=91?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/ets/component/VideoPlayComponent.ets | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/windowpiplibrary/src/main/ets/component/VideoPlayComponent.ets b/windowpiplibrary/src/main/ets/component/VideoPlayComponent.ets index 5e59bb0..1f40f05 100644 --- a/windowpiplibrary/src/main/ets/component/VideoPlayComponent.ets +++ b/windowpiplibrary/src/main/ets/component/VideoPlayComponent.ets @@ -219,18 +219,20 @@ export struct VideoPlayComponent { .height($r('app.integer.auto_button_height')) .selectedColor($r('sys.color.brand')) .onChange(async (isOn: boolean) => { - this.isAutoPull = isOn; if (isOn) { if (this.curBp === 'xl') { this.showToast(); return; } - if (!this.pipController) { - await this.createPipController(); - } - this.pipController?.setAutoStartEnabled(this.isAutoPull); - this.hintMsgVisibility = true; } + + this.isAutoPull = isOn; + if (!this.pipController) { + await this.createPipController(); + } + this.pipController?.setAutoStartEnabled(this.isAutoPull); + this.hintMsgVisibility = true; + }) } .width(CommonConstants.FULL_PERCENT) -- Gitee