图层窗口相关修复

This commit is contained in:
Lenheart 2024-12-17 10:00:33 +08:00
parent e8841a5dc2
commit df5f1c31b6
3 changed files with 11 additions and 2 deletions

View File

@ -19,6 +19,9 @@ class Layer extends Actor {
//设置图层裁剪区域
function SetClipRect(x, y, w, h) {
if (!IsLayer) {
print("SetClipRect:窗口不是图层窗口");
}
LayerActor_SetClipRect(this.C_Object, x, y, w, h);
}

View File

@ -184,7 +184,10 @@ class Yosin_Window extends Yosin_BaseWindow {
//是否为独立窗口
IsIndependent = true;
constructor(gObjectId, gX, gY, gWidth, gHeight, gTitleH, IsLayer = false) {
//是否为图层窗口
IsLayer = false;
constructor(gObjectId, gX, gY, gWidth, gHeight, gTitleH) {
ObjectId = gObjectId;
//宽度
Width = gWidth;

View File

@ -79,6 +79,9 @@ class _Select_Character_SettingBackground_Window extends Yosin_Window {
//是否为独立窗口
IsIndependent = false;
//是否为图层窗口
IsLayer = true;
//是否可见
Visible = false;
@ -91,7 +94,7 @@ class _Select_Character_SettingBackground_Window extends Yosin_Window {
ScrollObject = null;
constructor(gObjectId, gX, gY, gWidth, gHeight, gTitleH) {
base.constructor(gObjectId, gX, gY, gWidth, gHeight, gTitleH, true);
base.constructor(gObjectId, gX, gY, gWidth, gHeight, gTitleH);
SettingBackgroundButtonList = [];
SetClipRect(5, 9, gWidth, gHeight - 9);