Commit c6da07f9 authored by 邱旭's avatar 邱旭

M:wq

ge branch 'dev' of http://gitlab2.dui88.com/wanghongyuan/xiaoxiaole into dev
parents b7d05af7 616485b1
......@@ -23,7 +23,7 @@
<e:Group id="selbox" width="531" y="427.37" horizontalCenter="0.5">
<e:Group id="selbox" width="531" y="427.37" horizontalCenter="6.5">
<e:Group id="zhuanpan" width="531" height="121" scaleX="1" scaleY="1" horizontalCenter="0" top="0">
<e:Image source="itembg_png" horizontalCenter="0" verticalCenter="0"/>
<e:Image source="bloodhert_png" x="12" verticalCenter="6.5"/>
......@@ -78,8 +78,8 @@
</e:Group>
</e:Group>
<e:Group id="botinfo" width="750" height="170" y="846.45" horizontalCenter="0">
<e:Image id="countheart" source="bloodhert_png" x="273.28" scaleX="0.4" scaleY="0.4" y="11"/>
<e:Label id="countdownTxt" text="恢复:00:32:41" size="24" width="509" verticalAlign="middle" textAlign="left" x="314" scaleX="1" scaleY="1" y="13" textColor="0xc17343" fontFamily="FZY3JW" bold="false"/>
<e:Image id="countheart" source="bloodhert_png" x="257.3" scaleX="0.4" scaleY="0.4" y="11"/>
<e:Label id="countdownTxt" text="恢复 : 00 : 32 : 41" size="24" width="509" verticalAlign="middle" textAlign="left" x="298.02" scaleX="1" scaleY="1" y="13" textColor="0xc17343" fontFamily="FZY3JW" bold="false"/>
<e:Button id="resumeBtn" label="" y="50" horizontalCenter="0" x="189" scaleX="1" scaleY="1">
<e:skinName>
<e:Skin states="up,down,disabled">
......
......@@ -2,10 +2,12 @@ export default class CountDown extends egret.EventDispatcher {
_txt: eui.Label;
_timer: egret.Timer;
_func;
constructor(txt?,func?) {
_addspace:boolean = false;
constructor(txt?,func?,addspace=false) {
super();
this._txt = txt;
this._func = func;
this._addspace = addspace;
this._timer = new egret.Timer(1000);
this._timer.addEventListener(egret.TimerEvent.TIMER, this.onTimer, this);
this._timer.addEventListener(egret.TimerEvent.TIMER_COMPLETE, this.onTimerComplete, this);
......@@ -25,7 +27,12 @@ export default class CountDown extends egret.EventDispatcher {
const h = Math.floor( left / 3600);
const m = Math.floor ( (left % 3600) / 60 );
const s = left % 3600 % 60;
if(this._addspace){
this._txt.text = `${this.getNumber(h)} : ${this.getNumber(m)} : ${this.getNumber(s)}`;
}else{
this._txt.text = `${this.getNumber(h)}:${this.getNumber(m)}:${this.getNumber(s)}`;
}
if(this._func) {
this._txt.text = this._func(this._txt.text);
}
......
......@@ -46,8 +46,11 @@ export default class BloodPanel extends Panel {
//是否显示抽奖得体力
var showcj:boolean = false;
if(res&&res.data&&res.data.luckyDrawConf&&res.data.luckyDrawConf.enable){
var bloodadd = res.data.luckyDrawConf.prizeList.filter(item => item.categoryType == 2);
if(bloodadd.length>0){
showcj = true;
}
}
//显示条数
var tipnum:number = 3;
//有无按钮
......
This diff is collapsed.
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