diff --git a/src/Editor/DefaultConfig.ts b/src/Editor/DefaultConfig.ts index 99cfdac5e..13cebdd93 100644 --- a/src/Editor/DefaultConfig.ts +++ b/src/Editor/DefaultConfig.ts @@ -994,7 +994,7 @@ export const DefaultR2b2Option: IRect2Br2Option = { Object.freeze(DefaultR2b2Option); export const DefaultHSOption: IHSOption = { - version: 6, + version: 7, isAll: true, isHide: true, isDelete: false, @@ -1029,7 +1029,8 @@ export const DefaultHSOption: IHSOption = { pointLight: false, rectAreaLight: false, customBoardName: "", - matchType: ECompareType.Equal + matchType: ECompareType.Equal, + text: false, }; export const DefaultCommonPanelOption: CommonPanelConfigOption = { diff --git a/src/UI/Components/Modal/HideSelectModal.tsx b/src/UI/Components/Modal/HideSelectModal.tsx index 6212d769c..7383db95c 100644 --- a/src/UI/Components/Modal/HideSelectModal.tsx +++ b/src/UI/Components/Modal/HideSelectModal.tsx @@ -29,6 +29,7 @@ import { RectAreaLight } from '../../../DatabaseServices/Lights/RectAreaLight'; import { SpotLight } from '../../../DatabaseServices/Lights/SpotLight'; import { ProcessingGroupRecord } from '../../../DatabaseServices/ProcessingGroup/ProcessingGroupRecord'; import { TemplateRecord } from '../../../DatabaseServices/Template/TemplateRecord'; +import { Text } from '../../../DatabaseServices/Text/Text'; import { CommandWrap } from '../../../Editor/CommandMachine'; import { PromptStatus } from '../../../Editor/PromptResult'; import { SelectSetBase } from '../../../Editor/SelectBase'; @@ -79,8 +80,8 @@ export const KEY2LABEL: AllString = { custom: '板名', spotlight: "射灯", pointLight: "点光源", - rectAreaLight: "矩形光源" - + rectAreaLight: "矩形光源", + text: "文字", }; const BOARD_KEYS = [ @@ -98,7 +99,7 @@ const CURVE_KEYS = [ "curve", "line", "polyline", "circle", "arc" ]; const OTHERS = [ - "dim", "visual" + "dim", "visual", "text" ]; const LIGHTING = [ "spotlight", "pointLight", "rectAreaLight" @@ -685,6 +686,11 @@ export class HideSelectModal extends React.Component<{ store: HideSelectStore; h if (option.visual) resEntSet.add(e); } + if (e instanceof Text) + { + if (option.text) + resEntSet.add(e); + } } return resEntSet; }; diff --git a/src/UI/Store/HSInterface.ts b/src/UI/Store/HSInterface.ts index bc93bb2e0..2c917f09f 100644 --- a/src/UI/Store/HSInterface.ts +++ b/src/UI/Store/HSInterface.ts @@ -38,4 +38,5 @@ export interface IHSOption extends IBaseOption spotlight?: boolean; //射灯 pointLight?: boolean; //点光源 rectAreaLight?: boolean; //矩形光 + text: boolean; } diff --git a/src/UI/Store/HideSelectStore.ts b/src/UI/Store/HideSelectStore.ts index 8a7f9abf9..ac73c0dac 100644 --- a/src/UI/Store/HideSelectStore.ts +++ b/src/UI/Store/HideSelectStore.ts @@ -70,6 +70,11 @@ export class HideSelectStore implements IConfigStore cof.option.rectAreaLight = false; cof.option.pointLight = false; } + if (cof.option.version < 7) + { + cof.option.version = 7; + cof.option.text = false; + } Object.assign(this.m_Option, cof.option); this.CheckIsAll(); this.isRev = false;