Compare commits
	
		
			No commits in common. "dec18361ef5dbde0fcac783dd2ad13bd01b0d294" and "c10dd6e882b7ec65131a148149ea52065b986418" have entirely different histories.
		
	
	
		
			dec18361ef
			...
			c10dd6e882
		
	
		
| @ -112,6 +112,5 @@ const EN_US = { | |||||||
|     "Panel.Info.Label.Details.Error.Unspecified": "Label object not specified", |     "Panel.Info.Label.Details.Error.Unspecified": "Label object not specified", | ||||||
|     "Panel.Info.Label.List.Error.Nodata": "There are no labels in the model, click the button to create", |     "Panel.Info.Label.List.Error.Nodata": "There are no labels in the model, click the button to create", | ||||||
|     "Panel.Info.Behavior.Details.Error.Not.Behavior": "Please specify a behavior first to view the details", |     "Panel.Info.Behavior.Details.Error.Not.Behavior": "Please specify a behavior first to view the details", | ||||||
|     "Panel.Info.Behavior.Details.Behavior.Props": "{behavior} parameter", |  | ||||||
| } | } | ||||||
| export default EN_US; | export default EN_US; | ||||||
| @ -112,6 +112,5 @@ const ZH_CN = { | |||||||
|     "Panel.Info.Label.Details.Error.Unspecified": "未指定标签对象", |     "Panel.Info.Label.Details.Error.Unspecified": "未指定标签对象", | ||||||
|     "Panel.Info.Label.List.Error.Nodata": "模型中没有标签,点击按钮以创建", |     "Panel.Info.Label.List.Error.Nodata": "模型中没有标签,点击按钮以创建", | ||||||
|     "Panel.Info.Behavior.Details.Error.Not.Behavior": "请先指定一个行为以查看详情", |     "Panel.Info.Behavior.Details.Error.Not.Behavior": "请先指定一个行为以查看详情", | ||||||
|     "Panel.Info.Behavior.Details.Behavior.Props": "{behavior}参数", |  | ||||||
| } | } | ||||||
| export default ZH_CN; | export default ZH_CN; | ||||||
| @ -6,11 +6,6 @@ import type { Model } from "./Model"; | |||||||
| import type { Range } from "./Range"; | import type { Range } from "./Range"; | ||||||
| import type { Label } from "./Label"; | import type { Label } from "./Label"; | ||||||
| 
 | 
 | ||||||
| type IObjectParamCacheType<P, Q = P> = { |  | ||||||
|     picker: P; |  | ||||||
|     objects: Q; |  | ||||||
| } |  | ||||||
| 
 |  | ||||||
| /** | /** | ||||||
|  * 参数类型 |  * 参数类型 | ||||||
|  */ |  */ | ||||||
| @ -21,10 +16,12 @@ type IMapBasicParamTypeKeyToType = { | |||||||
| } | } | ||||||
| 
 | 
 | ||||||
| type IMapObjectParamTypeKeyToType = { | type IMapObjectParamTypeKeyToType = { | ||||||
|     "R": IObjectParamCacheType<Range | undefined>; |     "R"?: Range; | ||||||
|     "G": IObjectParamCacheType<Group | undefined>; |     "G"?: Group; | ||||||
|     "LR": IObjectParamCacheType<Label | Range | undefined, Range[]>; |     "GR"?: Group | Range; | ||||||
|     "LG": IObjectParamCacheType<Label | Group | undefined, Range[]>; |     "LR"?: Label | Range; | ||||||
|  |     "LG"?: Label | Group; | ||||||
|  |     "LGR"?: Label | Group | Range; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| type IMapVectorParamTypeKeyToType = { | type IMapVectorParamTypeKeyToType = { | ||||||
| @ -43,7 +40,7 @@ type IParamValue<K extends IParamType> = AllMapType[K]; | |||||||
| /** | /** | ||||||
|  * 特殊对象类型判定 |  * 特殊对象类型判定 | ||||||
|  */ |  */ | ||||||
| const objectTypeListEnumSet = new Set<IParamType>(["R", "G", "LR", "LG"]); | const objectTypeListEnumSet = new Set<IParamType>(["R", "G", "GR", "LR", "LG", "LGR"]); | ||||||
| 
 | 
 | ||||||
| /** | /** | ||||||
|  * 对象断言表达式 |  * 对象断言表达式 | ||||||
| @ -250,22 +247,6 @@ class BehaviorRecorder< | |||||||
|                     case "vec": |                     case "vec": | ||||||
|                         defaultObj[key] = [0, 0, 0] as any; |                         defaultObj[key] = [0, 0, 0] as any; | ||||||
|                         break; |                         break; | ||||||
|                      |  | ||||||
|                     case "G": |  | ||||||
|                     case "R": |  | ||||||
|                         defaultObj[key] = { |  | ||||||
|                             picker: undefined, |  | ||||||
|                             objects: undefined |  | ||||||
|                         } as any; |  | ||||||
|                         break; |  | ||||||
| 
 |  | ||||||
|                     case "LR": |  | ||||||
|                     case "LG": |  | ||||||
|                         defaultObj[key] = { |  | ||||||
|                             picker: undefined, |  | ||||||
|                             objects: [] |  | ||||||
|                         } as any; |  | ||||||
|                         break; |  | ||||||
|                 } |                 } | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|  | |||||||
| @ -4,8 +4,6 @@ import { Behavior } from "@Model/Behavior"; | |||||||
| import { Message } from "@Component/Message/Message"; | import { Message } from "@Component/Message/Message"; | ||||||
| import { AttrInput } from "@Component/AttrInput/AttrInput"; | import { AttrInput } from "@Component/AttrInput/AttrInput"; | ||||||
| import { ColorInput } from "@Component/ColorInput/ColorInput"; | import { ColorInput } from "@Component/ColorInput/ColorInput"; | ||||||
| import { TogglesInput } from "@Component/TogglesInput/TogglesInput"; |  | ||||||
| import { ConfirmPopup } from "@Component/ConfirmPopup/ConfirmPopup"; |  | ||||||
| import "./BehaviorDetails.scss"; | import "./BehaviorDetails.scss"; | ||||||
| 
 | 
 | ||||||
| interface IBehaviorDetailsProps {} | interface IBehaviorDetailsProps {} | ||||||
| @ -33,34 +31,6 @@ class BehaviorDetails extends Component<IBehaviorDetailsProps & IMixinStatusProp | |||||||
|                 }} |                 }} | ||||||
|             /> |             /> | ||||||
| 
 | 
 | ||||||
|             <TogglesInput |  | ||||||
| 				keyI18n="Common.Attr.Key.Delete" red |  | ||||||
| 				onIconName="delete" offIconName="delete" |  | ||||||
| 				valueChange={() => { |  | ||||||
| 					if (this.props.status) { |  | ||||||
|                         const status = this.props.status; |  | ||||||
|                         status.popup.showPopup(ConfirmPopup, { |  | ||||||
|                             infoI18n: "Popup.Delete.Behavior.Confirm", |  | ||||||
|                             titleI18N: "Popup.Action.Objects.Confirm.Title", |  | ||||||
|                             yesI18n: "Popup.Action.Objects.Confirm.Delete", |  | ||||||
|                             red: "yes", |  | ||||||
|                             yes: () => { |  | ||||||
|                                 status.model.deleteBehavior(behavior); |  | ||||||
|                                 status.setBehaviorObject(); |  | ||||||
|                             } |  | ||||||
|                         }) |  | ||||||
|                     } |  | ||||||
| 				}} |  | ||||||
| 			/> |  | ||||||
| 
 |  | ||||||
|             <Message |  | ||||||
|                 isTitle |  | ||||||
|                 i18nKey="Panel.Info.Behavior.Details.Behavior.Props" |  | ||||||
|                 options={{ |  | ||||||
|                     behavior: behavior.getTerms(behavior.behaviorName) |  | ||||||
|                 }} |  | ||||||
|             /> |  | ||||||
| 
 |  | ||||||
|         </>; |         </>; | ||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -63,7 +63,6 @@ class BehaviorList extends Component<IBehaviorListProps & IMixinStatusProps & IM | |||||||
|                             red: "yes", |                             red: "yes", | ||||||
|                             yes: () => { |                             yes: () => { | ||||||
|                                 status.model.deleteBehavior(behavior); |                                 status.model.deleteBehavior(behavior); | ||||||
|                                 status.setBehaviorObject(); |  | ||||||
|                             } |                             } | ||||||
|                         }) |                         }) | ||||||
|                     } |                     } | ||||||
|  | |||||||
| @ -121,11 +121,9 @@ class GroupDetails extends Component<IGroupDetailsProps & IMixinStatusProps & IM | |||||||
|                 behavior={group.behaviors} |                 behavior={group.behaviors} | ||||||
|                 focusBehavior={this.props.status?.focusBehavior} |                 focusBehavior={this.props.status?.focusBehavior} | ||||||
|                 click={(behavior) => { |                 click={(behavior) => { | ||||||
|                     if (behavior.isDeleted()) return; |  | ||||||
|                     this.props.status?.setBehaviorObject(behavior); |                     this.props.status?.setBehaviorObject(behavior); | ||||||
|                 }} |                 }} | ||||||
|                 action={(behavior) => { |                 action={(behavior) => { | ||||||
|                     if (behavior.isDeleted()) return; |  | ||||||
|                     this.props.status?.setBehaviorObject(behavior); |                     this.props.status?.setBehaviorObject(behavior); | ||||||
|                     setTimeout(() => { |                     setTimeout(() => { | ||||||
|                         this.props.setting?.layout.focus("BehaviorDetails"); |                         this.props.setting?.layout.focus("BehaviorDetails"); | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user