Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hw_online_010
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
template admin
hw_online_010
Commits
bba74941
Commit
bba74941
authored
Apr 01, 2020
by
limingzhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update preload audio
parent
ed63dcea
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
4 deletions
+12
-4
Cartoon.ts
src/app/play/Cartoon.ts
+4
-2
play.component.ts
src/app/play/play.component.ts
+8
-2
No files found.
src/app/play/Cartoon.ts
View file @
bba74941
...
...
@@ -140,13 +140,15 @@ export class Cartoon {
return
new
Promise
((
resolve
,
reject
)
=>
{
const
audio
=
new
Audio
();
audio
.
oncanplay
=
a
=>
{
resolve
(
audio
);
//
resolve(audio);
};
audio
.
onerror
=
()
=>
{
reject
();
};
audio
.
src
=
url
;
audio
.
load
();
resolve
(
audio
);
});
}
...
...
@@ -249,4 +251,4 @@ export class Cartoon {
}
animation
=
new
CartoonAnimation
(
this
)
}
\ No newline at end of file
}
src/app/play/play.component.ts
View file @
bba74941
...
...
@@ -687,10 +687,10 @@ export class PlayComponent implements OnInit, OnDestroy {
this
.
initGroup
();
if
(
this
.
g_teacherFlag
){
this
.
initStartButton
()
this
.
initTeacherListener
()
//
this.initTeacherListener()
}
else
{
this
.
initCover
()
this
.
initStudentListener
();
//
this.initStudentListener();
}
}
...
...
@@ -1987,6 +1987,12 @@ export class PlayComponent implements OnInit, OnDestroy {
this
.
update
();
this
.
systemReady
();
if
(
this
.
g_teacherFlag
){
this
.
initTeacherListener
()
}
else
{
this
.
initStudentListener
();
}
window
[
"
air
"
].
hideAirClassLoading
(
this
.
g_KEY
,
this
.
g_data
);
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment