Commit 9eb13bc0 authored by 范雪寒's avatar 范雪寒

fix: addServerListener

parent 572ae4f2
......@@ -117,7 +117,7 @@ cc.Class({
addPreloadImage() {
const arr = this.data.options;
if (arr) {
for (let i=0; i<arr.length; i++) {
for (let i = 0; i < arr.length; i++) {
this._imageResList.push({ url: arr[i].image });
}
}
......@@ -134,16 +134,12 @@ cc.Class({
addServerListener() {
const c = window.courseware;
if (!c) {
return;
}
c.onEvent('course-in-screen', (data, next) => {
window.air.onCourseInScreen = (next) => {
cc.find('Canvas').opacity = 255;
this.showTemplateStartAnima();
this.loadEnd();
next();
});
}
},
showTemplateStartAnima() {
......@@ -299,12 +295,12 @@ cc.Class({
if (!window.courseware) {
return;
}
window.courseware.onEvent('clickOption', (data, next) => {
this.showOption(data.data.idx);
window.courseware.onEvent('clickOption', async (data, next) => {
await this.showOption(data.data.idx);
next();
});
window.courseware.onEvent('clickQuestion', (data, next) => {
this.showQuestion();
window.courseware.onEvent('clickQuestion', async (data, next) => {
await this.showQuestion();
next();
});
window.courseware.onEvent('hideOption', (data, next) => {
......
{"ios":{"sceneName":"AK09","version":"fcbf3"},"android":{"sceneName":"AK09","version":"fcbf3"}}
\ No newline at end of file
{"ios":{"sceneName":"AK09","version":"2a5a4"},"android":{"sceneName":"AK09","version":"2a5a4"}}
\ No newline at end of file
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