Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
YM4-13
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
YM4-13
Commits
73bda07a
Commit
73bda07a
authored
Oct 31, 2020
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add degug log
parent
99310336
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
play.component.ts
src/app/play/play.component.ts
+6
-1
No files found.
src/app/play/play.component.ts
View file @
73bda07a
...
@@ -87,6 +87,7 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -87,6 +87,7 @@ export class PlayComponent implements OnInit, OnDestroy {
g_firstTouch
=
true
;
g_firstTouch
=
true
;
g_partTitle_x
=
null
;
g_partTitle_x
=
null
;
g_mainTitle_x
=
null
;
g_mainTitle_x
=
null
;
g_dragDelay
=
300
//放置拖拽事件触发播放音效
// ------------------------------------
// ------------------------------------
// ------------ 私有数据 ------------
// ------------ 私有数据 ------------
...
@@ -535,13 +536,16 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -535,13 +536,16 @@ export class PlayComponent implements OnInit, OnDestroy {
element
.
timeoutID
=
null
element
.
timeoutID
=
null
this
.
subscribeMapDragEvent
(
element
.
id
,
()
=>
{
this
.
subscribeMapDragEvent
(
element
.
id
,
()
=>
{
console
.
log
(
element
.
id
,
"
触发点击
"
)
element
.
timeoutID
=
setTimeout
(()
=>
{
element
.
timeoutID
=
setTimeout
(()
=>
{
if
(
item
.
media
.
audio_url
)
{
if
(
item
.
media
.
audio_url
)
{
console
.
log
(
element
.
id
,
"
触发播放音频
"
)
this
.
g_cartoon
.
stopAllAudio
()
this
.
g_cartoon
.
stopAllAudio
()
this
.
g_cartoon
.
playAudio
(
item
.
media
.
audio_url
)
this
.
g_cartoon
.
playAudio
(
item
.
media
.
audio_url
)
}
}
},
500
);
},
this
.
g_dragDelay
);
},
()
=>
{
},
()
=>
{
console
.
log
(
element
.
id
,
"
触发拖动
"
)
if
(
element
.
timeoutID
)
{
if
(
element
.
timeoutID
)
{
clearTimeout
(
element
.
timeoutID
)
clearTimeout
(
element
.
timeoutID
)
element
.
timeoutID
=
null
element
.
timeoutID
=
null
...
@@ -549,6 +553,7 @@ export class PlayComponent implements OnInit, OnDestroy {
...
@@ -549,6 +553,7 @@ export class PlayComponent implements OnInit, OnDestroy {
elementDrag
.
ref
.
x
=
this
.
g_clickX
,
elementDrag
.
ref
.
x
=
this
.
g_clickX
,
elementDrag
.
ref
.
y
=
this
.
g_clickY
elementDrag
.
ref
.
y
=
this
.
g_clickY
},
()
=>
{
},
()
=>
{
console
.
log
(
element
.
id
,
"
触发释放
"
)
elementDrag
.
ref
.
x
=
elementDrag
.
initX
,
elementDrag
.
ref
.
x
=
elementDrag
.
initX
,
elementDrag
.
ref
.
y
=
elementDrag
.
initY
elementDrag
.
ref
.
y
=
elementDrag
.
initY
this
.
m_elementDraged
=
element
.
id
;
this
.
m_elementDraged
=
element
.
id
;
...
...
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