Commit 19da1133 by libai

测试

parent 5aa5dc57
Showing with 21 additions and 11 deletions
...@@ -666,22 +666,32 @@ $(function(){ ...@@ -666,22 +666,32 @@ $(function(){
moreMc() moreMc()
return; return;
} }
var soundOk=false
html+='<video muted id="myVideo" autoplay webkit-playsinline="true" x-webkit-airplay="true" playsinline="true" x5-video-player-type="h5" x5-video-player-fullscreen="true" style="height:100%;object-fit:fill;position:absolute;z-index: 10" poster="" src="'+data.pullFlowUrlHLS+'"></video>' html+='<video muted id="myVideo" autoplay webkit-playsinline="true" x-webkit-airplay="true" playsinline="true" x5-video-player-type="h5" x5-video-player-fullscreen="true" style="height:100%;object-fit:fill;position:absolute;z-index: 10" poster="" src="'+data.pullFlowUrlHLS+'"></video>'
$(".video-box").html(html) $(".video-box").html(html)
$("#myVideo").on("canplay",function(){
$(".sound-btn").unbind("click").on("click",function(){ $(".sound-btn").unbind("click").on("click",function(){
var _self=$(this) var _self=$(this)
if(_self.attr("data-type")==1){ if(_self.attr("data-type")==1){
_self.attr("data-type","0") _self.attr("data-type","0")
$(".sound-btn").attr("src","images/sound-no.png")
$(".video-box video").prop("muted",true)
}else {
_self.attr("data-type","1")
$(".sound-btn").attr("src","images/sound-yes.png")
$(".video-box video").prop("muted",false)
}
})
$("body").on("click",function(){
if(soundOk==true)return;
soundOk=true
$(".sound-btn").attr("data-type","0")
$(".sound-btn").attr("src","images/sound-no.png") $(".sound-btn").attr("src","images/sound-no.png")
$(".video-box video").prop("muted",true) $(".video-box video").prop("muted",true)
}else { })
_self.attr("data-type","1")
$(".sound-btn").attr("src","images/sound-yes.png")
$(".video-box video").prop("muted",false)
}
}) })
giftList(1) giftList(1)
if(localStorage.uid!=undefined){ if(localStorage.uid!=undefined){
myDiamond() myDiamond()
......
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 sign in to comment