继续补充UI细节

This commit is contained in:
2025-05-30 15:24:21 +08:00
parent a4dff5c7eb
commit 009cafe5fe
6 changed files with 3015 additions and 3071 deletions

View File

@@ -51,10 +51,6 @@ export class CalendarUnit extends Laya.Script {
this.pieSize = this.sprite_pie.width /2
}
public onInit(label_obj: Laya.Label): void {
this.label_show = label_obj
}
public setCalendarUnit(year: number, month: number, day: number, open: boolean, progress: number, handler: any, func: any): void {
this.selected = false
this.year = year

View File

@@ -69,9 +69,6 @@ export class DailyChallenge extends Laya.Script {
@property(Laya.Box)
public obj_items: Laya.Box
@property(Laya.Box)
public obj_labels: Laya.Box
private units: Array<CalendarUnit> = []
private selectedUnit: CalendarUnit
@@ -114,12 +111,9 @@ export class DailyChallenge extends Laya.Script {
for (let i = 0; i < this.obj_items.numChildren; i++) {
const hbox = this.obj_items.getChildAt(i)
const l_hbox = this.obj_labels.getChildAt(i)
for (let j = 0; j < hbox.numChildren; j++) {
const unit = hbox.getChildAt(j).getComponent(CalendarUnit)
const l_obj = l_hbox.getChildAt(j) as Laya.Label
this.units.push(unit)
unit.onInit(l_obj)
}
}