Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
H
hello_taobao
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
wildfirecode13
hello_taobao
Commits
431d8ca8
Commit
431d8ca8
authored
Sep 14, 2020
by
wildfirecode13
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
837abb20
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
20 additions
and
17 deletions
+20
-17
pagehuo_dong_ye.acss
dist/pages/pagehuo_dong_ye/pagehuo_dong_ye.acss
+2
-2
pagejie_shu_ye.acss
dist/pages/pagejie_shu_ye/pagejie_shu_ye.acss
+2
-2
pagejie_shu_ye.js
dist/pages/pagejie_shu_ye/pagejie_shu_ye.js
+15
-12
playBgMusic.js
dist/utils/playBgMusic.js
+1
-1
No files found.
dist/pages/pagehuo_dong_ye/pagehuo_dong_ye.acss
View file @
431d8ca8
...
...
@@ -32,8 +32,8 @@
width: 56rpx;
height: 56rpx;
opacity: 1;
left:
2
24rpx;
top: 2
4
2rpx;
left:
5
24rpx;
top: 2
6
2rpx;
position: absolute;
}
...
...
dist/pages/pagejie_shu_ye/pagejie_shu_ye.acss
View file @
431d8ca8
...
...
@@ -22,8 +22,8 @@
width: 56rpx;
height: 56rpx;
opacity: 1;
left:
2
24rpx;
top: 2
4
2rpx;
left:
5
24rpx;
top: 2
6
2rpx;
position: absolute;
}
...
...
dist/pages/pagejie_shu_ye/pagejie_shu_ye.js
View file @
431d8ca8
...
...
@@ -5,6 +5,7 @@ import API from '../../api';
import
{
SHARE_CONFIG
}
from
'/tbcc-sdk/lib/constants'
;
import
playBgMusic
from
'/utils/playBgMusic'
;
const
app
=
getApp
();
let
musicUrl
=
null
;
Page
({
data
:
{
prizeVisible
:
false
,
...
...
@@ -25,7 +26,7 @@ Page({
list
:
''
,
totalFloor
:
''
,
listlength
:
''
,
musicSwitch
:
true
musicSwitch
:
true
},
onLoad
(
props
)
{
...
...
@@ -90,13 +91,13 @@ Page({
onShareAppMessage
()
{
return
SHARE_CONFIG
;
},
onmusicSwitch
(){
let
{
musicSwitch
}
=
this
.
data
;
onmusicSwitch
()
{
let
{
musicSwitch
}
=
this
.
data
;
this
.
addMusic
(
musicSwitch
);
this
.
setData
({
musicSwitch
:
!
musicSwitch
musicSwitch
:
!
musicSwitch
})
console
.
log
(
'music点击后'
,
musicSwitch
);
console
.
log
(
'music点击后'
,
musicSwitch
);
},
...
...
@@ -346,15 +347,17 @@ Page({
maskVisible
:
false
})
},
async
addMusic
(
musicSwitch
){
async
addMusic
(
musicSwitch
)
{
if
(
!
musicUrl
)
{
const
resultSrc
=
await
app
.
cloud
.
file
.
getTempFileURL
({
fileId
:
'cloud://C7A066C702682E94326284DF8A2975CC//FILA_building_loop.mp3'
});
let
musicUrl
=
null
;
if
(
resultSrc
[
0
])
musicUrl
=
resultSrc
[
0
].
url
;
}
// let {musicSwitch} = this.data;
// playBgMusic(true,musicUrl)
playBgMusic
(
musicSwitch
,
musicUrl
);
playBgMusic
(
musicSwitch
,
musicUrl
);
console
.
log
(
'fuck music'
)
}
...
...
dist/utils/playBgMusic.js
View file @
431d8ca8
...
...
@@ -77,7 +77,7 @@ export const playBgMusic = (isOn, src) => {//待测试
}
}
else
{
if
(
bgs
[
key
])
{
// bgs[key].pause(); /// pause
垃圾
,不能用
// bgs[key].pause(); /// pause ,不能用
bgs
[
key
].
pause
();
// bgs[key].isOn = false; /// TODO 自己记一个开关,因为淘宝的玩意stop之后虽然听不到,但还是在播放,会触发loop播放和onEnded事件
}
...
...
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