Commit 31fde673 authored by Tt's avatar Tt

调整

parent cdf9b4a5
......@@ -797,17 +797,24 @@ cc.Class({
},
cardAction(card) {
return new Promise((resolve, reject) => {
pg.audio.playAudioByUrlCall(card.data.audio).then((id) => {
let time = cc.audioEngine.getDuration(id);
if (card.data.audio) {
pg.audio.playAudioByUrlCall(card.data.audio).then((id) => {
let time = cc.audioEngine.getDuration(id);
if (time < 0.5) time = 0.5;
else if (time > 1) time = 1;
cc.tween(card).to(time / 2, { scale: 1.1 }).to(time / 2, { scale: 1 }).call(() => { return resolve("") }).start();
})
} else {
let time = 0.8;
cc.tween(card).to(time / 2, { scale: 1.1 }).to(time / 2, { scale: 1 }).call(() => { return resolve("") }).start();
});
}
});
},
showSliderAction(time) {
return new Promise((resolve, reject) => {
let card_group = cc.find("card_group", this.node);
let slider = cc.find("slider", card_group);
slider.action = true;
slider.active = true;
let handle = cc.find("Handle", slider);
handle.active = true;
let sl = slider.getComponent(cc.Slider)
......
......@@ -141,7 +141,7 @@
</div>
<div style="margin:10px">
<span>是否标红</span>
<nz-radio-group [(ngModel)]="obj.color">
<nz-radio-group [(ngModel)]="obj.color" (ngModelChange)="saveItem()">
<label nz-radio nzValue="1"></label>
<label nz-radio nzValue="0"></label>
</nz-radio-group>
......
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