Commit c791db39 authored by 李维's avatar 李维

修改进度条显示隐藏效果

parent 1fb02d49
...@@ -1643,15 +1643,20 @@ cc.Class({ ...@@ -1643,15 +1643,20 @@ cc.Class({
clearTimeout(this.timeoutHideBarId); clearTimeout(this.timeoutHideBarId);
} }
if(!this.isShowProgressBar) { if(this.isShowProgressBar) {
// 如果当前没有显示进度条 // 如果当前显示进度条
this.videoControlBar.emit("show_bar", withAnimation);
}
this.isShowProgressBar = true;
this.timeoutHideBarId = setTimeout(()=>{
this.videoControlBar.emit("hide_bar", true); this.videoControlBar.emit("hide_bar", true);
this.isShowProgressBar = false; this.isShowProgressBar = false;
}, 2000) } else {
// 如果当前显示进度条
this.videoControlBar.emit("show_bar", withAnimation);
this.isShowProgressBar = true;
this.timeoutHideBarId = setTimeout(()=>{
this.videoControlBar.emit("hide_bar", true);
this.isShowProgressBar = false;
}, 2000)
}
}, },
canvasTouchStart(e) { canvasTouchStart(e) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment