2025-01-02 12:15:45 +08:00
|
|
|
|
using CG.Framework;
|
|
|
|
|
|
using CG.UTility;
|
|
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
/*******************************************************************************
|
|
|
|
|
|
*Create By CG
|
|
|
|
|
|
*Function
|
|
|
|
|
|
*******************************************************************************/
|
|
|
|
|
|
namespace ZXK.LouDiXvMuNiu
|
|
|
|
|
|
{
|
|
|
|
|
|
public class VideoShowPanel : UIBase
|
|
|
|
|
|
{
|
|
|
|
|
|
private VCRCustom _videoCtrl;
|
|
|
|
|
|
private Action _exitEvent;
|
|
|
|
|
|
protected override void Awake()
|
|
|
|
|
|
{
|
|
|
|
|
|
base.Awake();
|
|
|
|
|
|
_videoCtrl = GetWedage("VCRPanel_N").GetComponent<VCRCustom>();
|
|
|
|
|
|
AddEventListener("ExitVideoBtn_N", UIEventType.OnButtonClick, () =>
|
|
|
|
|
|
{
|
|
|
|
|
|
_exitEvent?.Invoke();
|
|
|
|
|
|
UI_Manage.Instance.ClosePanel("VideoShowPanel");
|
2025-01-03 08:42:56 +08:00
|
|
|
|
UI_Manage.Instance.ClosePanel("VideoShowNoCtrlPanel");
|
2025-01-02 12:15:45 +08:00
|
|
|
|
});
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public void PlayVideoClip(string clipName,Action exitEvent)
|
|
|
|
|
|
{
|
|
|
|
|
|
_exitEvent = exitEvent;
|
|
|
|
|
|
//TODO <20><>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD>
|
|
|
|
|
|
string _videoPath = Application.streamingAssetsPath + ConstCtrl.VIDEO_CSDY_PATH+clipName+".mp4";
|
|
|
|
|
|
_videoCtrl.GetComponent<VCRCustom>().OnOpenVideoFile(_videoPath);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|