属性适配

This commit is contained in:
xu_yanfeng 2025-02-06 13:55:22 +08:00
parent ca8a4fd33a
commit 722a1a9695
2 changed files with 81 additions and 1 deletions

View File

@ -234,6 +234,58 @@ export function getEnumListConfig() {
},
],
},
{
type: cc.Graphics,
list: [
{
key: "lineJoin",
values() {
return cc.Graphics.LineJoin.__enums__;
},
},
{
key: "lineCap",
values() {
return cc.Graphics.LineCap.__enums__;
},
},
],
},
{
type: cc.Camera,
list: [
{
key: "clearFlags",
values() {
return cc.Camera.ClearFlag.__enums__;
},
},
{
key: "projection",
values() {
return cc.Camera.ProjectionType.__enums__;
},
},
{
key: "aperture",
values() {
return cc.Camera.Aperture.__enums__;
},
},
{
key: "shutter",
values() {
return cc.Camera.Shutter.__enums__;
},
},
{
key: "iso",
values() {
return cc.Camera.ISO.__enums__;
},
},
],
},
];
return enumConfig;
}

View File

@ -205,7 +205,33 @@ export function getSimpleProperties(typeName: string): string[] {
"cacheMode",
"useSystemFont",
];
config[CompType.Camera] = ["clearColor", "clearFlags", "cullingMask", "depth", "zoomRatio", "alignWithScreen"];
config[CompType.Graphics] = [
"lineWidth",
"lineJoin", //
"lineCap",
"strokeColor",
"fillColor",
"miterLimit",
];
config[CompType.Camera] = [
"clearColor", //
"clearFlags",
"cullingMask",
"depth",
"zoomRatio",
"priority",
"alignWithScreen",
"projection",
"far",
"near",
"clearDepth",
"clearStencil",
"orthoHeight",
"aperture",
"shutter",
"iso",
];
config[CompType.Spirte] = [
"atlas",
"spriteFrame",
@ -244,6 +270,8 @@ export function getSimpleProperties(typeName: string): string[] {
"fitWidth",
"fitHeight", //
"designResolution",
"cameraComponent",
"alignCanvasWithScreen",
];
return config[typeName] || [];
}