update
This commit is contained in:
@@ -219,11 +219,14 @@ export class GirlDetailPanel extends li_BaseView {
|
||||
for (let i = 0; i < stars.length; i++) {
|
||||
const element = stars[i];
|
||||
if (star > i) {
|
||||
ResManager.I.changeResourceSpriteFrame(element, "ui/common/heart");
|
||||
ResManager.I.changeResourceSpriteFrame(
|
||||
element,
|
||||
"ui/common/heart/heart"
|
||||
);
|
||||
} else {
|
||||
ResManager.I.changeResourceSpriteFrame(
|
||||
element,
|
||||
"ui/common/heart_empty"
|
||||
"ui/common/heart/heart_empty"
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,12 @@
|
||||
import { _decorator, Component, Node, instantiate, tween, Vec3 } from "cc";
|
||||
import {
|
||||
_decorator,
|
||||
Component,
|
||||
Node,
|
||||
instantiate,
|
||||
tween,
|
||||
Vec3,
|
||||
Label,
|
||||
} from "cc";
|
||||
import li_BaseView from "db://assets/Scripts/Main/Common/li_BaseView";
|
||||
import Utils from "db://assets/Scripts/Main/Common/Utils";
|
||||
import { GButton } from "db://assets/Scripts/Main/Common/GButton";
|
||||
@@ -8,6 +16,8 @@ import { DataManager, DataId } from "../../data/DataManager";
|
||||
import { GirlData } from "../../data/GirlData";
|
||||
import proto from "db://assets/Scripts/proto/proto.pb.js";
|
||||
import { NavigationManager, PanelType } from "../../manager/NavigationManager";
|
||||
import { ThemeData } from "../../data/ThemeData";
|
||||
import LanguageUtils from "../../../Main/Common/LanguageUtils";
|
||||
|
||||
const { ccclass, property } = _decorator;
|
||||
|
||||
@@ -24,6 +34,9 @@ export class GirlListPanel extends li_BaseView {
|
||||
private itemPool: GirlListItem[] = [];
|
||||
private maxPoolSize: number = 20;
|
||||
|
||||
private title1: Label;
|
||||
private title2: Label;
|
||||
|
||||
category: number;
|
||||
|
||||
onLoadCT() {
|
||||
@@ -36,6 +49,10 @@ export class GirlListPanel extends li_BaseView {
|
||||
this.itemInst = this._nodeTab.BubbleItem.getComponent(GirlListItem);
|
||||
this.itemInst.node.active = false;
|
||||
this.content = this._nodeTab.content;
|
||||
|
||||
this.title1 = this._nodeTab.title1.getComponent(Label);
|
||||
this.title2 = this._nodeTab.title2.getComponent(Label);
|
||||
|
||||
this.refresh();
|
||||
}
|
||||
|
||||
@@ -90,6 +107,11 @@ export class GirlListPanel extends li_BaseView {
|
||||
this.cache = [];
|
||||
}
|
||||
|
||||
// 主题数据
|
||||
const themeData = DataManager.I.getDataById<ThemeData>(DataId.Theme);
|
||||
const key = themeData.getLanKeyById(1001 + category);
|
||||
this.title1.string = this.title2.string = LanguageUtils.getText(key);
|
||||
|
||||
// 请求列表
|
||||
const reqData = {
|
||||
category,
|
||||
|
||||
Reference in New Issue
Block a user