添加横屏页面
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import { config } from "../../constants/config";
|
||||
|
||||
const { regClass, property } = Laya;
|
||||
|
||||
@regClass()
|
||||
@@ -89,6 +91,10 @@ export class CalendarUnit extends Laya.Script {
|
||||
|
||||
this.obj_star.visible = this.progress >= 1
|
||||
|
||||
var blockSize = 48
|
||||
if (config.H_SCREEN)
|
||||
blockSize = 33
|
||||
|
||||
if (this.selected) {
|
||||
this.label_show.color = "#ffffff"
|
||||
this.obj_selected.visible = true
|
||||
@@ -96,7 +102,7 @@ export class CalendarUnit extends Laya.Script {
|
||||
this.obj_pie.visible = true
|
||||
this.obj_mask.visible = true
|
||||
this.sprite_pie.graphics.clear()
|
||||
this.sprite_pie.graphics.drawPie(48, 48, 48, 0, 360*this.progress, "#ffffff")
|
||||
this.sprite_pie.graphics.drawPie(blockSize, blockSize, blockSize, 0, 360*this.progress, "#ffffff")
|
||||
this.sprite_mask.graphics.clear()
|
||||
this.sprite_mask.graphics.drawCircle(0.5, 0.5, 0.5, "#1d5cdc")
|
||||
}
|
||||
@@ -112,7 +118,7 @@ export class CalendarUnit extends Laya.Script {
|
||||
this.obj_pie.visible = true
|
||||
this.obj_mask.visible = true
|
||||
this.sprite_pie.graphics.clear()
|
||||
this.sprite_pie.graphics.drawPie(48, 48, 48, 0, 360*this.progress, "#2d3138")
|
||||
this.sprite_pie.graphics.drawPie(blockSize, blockSize, blockSize, 0, 360*this.progress, "#2d3138")
|
||||
this.sprite_mask.graphics.clear()
|
||||
this.sprite_mask.graphics.drawCircle(0.5, 0.5, 0.5, "#ffffff")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user