|
|
|
@ -77,6 +77,7 @@ |
|
|
|
showLayer: false, |
|
|
|
isResVideo: false, |
|
|
|
failUrl: uni.$http.baseUrl +"/profile//images/fail.gif", |
|
|
|
innerAudioContext: null, |
|
|
|
}; |
|
|
|
}, |
|
|
|
computed: { |
|
|
|
@ -105,6 +106,10 @@ |
|
|
|
this.videoHeight = res.screenHeight; |
|
|
|
} |
|
|
|
}); |
|
|
|
|
|
|
|
this.innerAudioContext = uni.createInnerAudioContext(); |
|
|
|
this.innerAudioContext.autoplay = true; |
|
|
|
this.innerAudioContext.src = "/static/videos/supermario.mp3"; |
|
|
|
|
|
|
|
// this.videoContext = uni.createVideoContext("video_play"); |
|
|
|
// this.videoContext.requestFullScreen(); |
|
|
|
@ -161,6 +166,7 @@ |
|
|
|
// 不为空表示答题错误展示返回重新选择 |
|
|
|
this.resCheck = true; |
|
|
|
this.question = false; |
|
|
|
this.innerAudioContext.play(); |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
@ -174,6 +180,7 @@ |
|
|
|
this.resCheck = false; |
|
|
|
this.resVideoUrl = ""; |
|
|
|
this.isResVideo = true; |
|
|
|
this.innerAudioContext.stop(); |
|
|
|
}, |
|
|
|
onMetadataLoaded(event) { |
|
|
|
if(this.isResVideo) { |
|
|
|
@ -183,6 +190,7 @@ |
|
|
|
} |
|
|
|
}, |
|
|
|
nextQuestion(outId, obj) { |
|
|
|
this.innerAudioContext.stop(); |
|
|
|
// 点击开始后先增加题次 |
|
|
|
if (2 == outId) { |
|
|
|
this.$api.addQuestionFre({ |
|
|
|
|