优化加载显示
This commit is contained in:
@@ -36,7 +36,8 @@ export class DetailImageItem extends Component {
|
||||
priceFrame: Node;
|
||||
@property(Label)
|
||||
videoPrice: Label;
|
||||
|
||||
@property(Node)
|
||||
loading: Node;
|
||||
base: GirlDetailPanel;
|
||||
url: string;
|
||||
isImage: boolean;
|
||||
@@ -142,8 +143,9 @@ export class DetailImageItem extends Component {
|
||||
this.category = category;
|
||||
this.girlId = id;
|
||||
this.resId = resId;
|
||||
this.question.active = true; // 显示问号,表示加载中
|
||||
//this.question.active = true; // 显示问号,表示加载中
|
||||
|
||||
this.loading.active = true;
|
||||
this.test_resID = this.node.getChildByName("resID");
|
||||
|
||||
this.test_resID.getComponent(Label).string =
|
||||
@@ -209,8 +211,9 @@ export class DetailImageItem extends Component {
|
||||
}
|
||||
|
||||
ResManager.I.changeBundleSpriteFrame(this.img, imgPath, "Girls", () => {
|
||||
this.question.active = false; // 图片加载成功后隐藏问号
|
||||
if (!this.isVisible) this.question.active = false; // 图片加载成功后隐藏问号
|
||||
this.scaleToFillItem();
|
||||
this.loading.active = false;
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user