|
@@ -70,14 +70,16 @@ public class RemoteVideoControl : MonoBehaviour
|
|
|
{
|
|
|
while (true)
|
|
|
{
|
|
|
- yield return new WaitForSeconds(0.5f);
|
|
|
+ yield return new WaitForSeconds(0.05f);
|
|
|
if (avProVideoPlayer.IsVideoReady()&& !AVideoSlide.isDown)
|
|
|
{
|
|
|
- textTotalTime.text = string.Format("{0}:{1}", (avProVideoPlayer.GetMaxTimer() / 60).ToString("00"), (avProVideoPlayer.GetMaxTimer() % 60).ToString("00"));
|
|
|
- currentTime.text = string.Format("{0}:{1}", (avProVideoPlayer.GetNowTimer() / 60).ToString("00"), (avProVideoPlayer.GetNowTimer() % 60).ToString("00"));
|
|
|
- slider.value = avProVideoPlayer.GetNowTimer() / avProVideoPlayer.GetMaxTimer();
|
|
|
+ float maxTimer = avProVideoPlayer.GetMaxTimer();
|
|
|
+ float nowTimer = avProVideoPlayer.GetNowTimer();
|
|
|
+ textTotalTime.text = string.Format("{0}:{1}", (maxTimer / 60).ToString("00"), (maxTimer % 60).ToString("00"));
|
|
|
+ currentTime.text = string.Format("{0}:{1}", (nowTimer / 60).ToString("00"), (nowTimer % 60).ToString("00"));
|
|
|
+ slider.value = maxTimer / nowTimer;
|
|
|
|
|
|
- if (slider.value > 0.99)
|
|
|
+ if (textTotalTime.text == currentTime.text)
|
|
|
{
|
|
|
Icon.SetActive(true);
|
|
|
Stop.SetActive(false);
|