Add clip details panel

This commit is contained in:
2022-05-02 16:09:02 +08:00
parent 7002d49155
commit e3681f2f32
11 changed files with 103 additions and 7 deletions
+13
View File
@@ -53,6 +53,7 @@ interface IStatusEvent {
labelAttrChange: void;
groupAttrChange: void;
behaviorAttrChange: void;
clipAttrChange: void;
individualChange: void;
behaviorChange: void;
popupChange: void;
@@ -286,6 +287,18 @@ class Status extends Emitter<IStatusEvent> {
}
}
/**
* 修改剪辑属性
*/
public changeClipAttrib<K extends keyof Clip>
(id: ObjectID, key: K, val: Clip[K]) {
const clip = this.model.getClipById(id);
if (clip && clip instanceof Clip) {
clip[key] = val;
this.emit("clipAttrChange");
}
}
public addGroupBehavior(id: ObjectID, val: Behavior) {
const group = this.model.getObjectById(id);
if (group && group instanceof Group) {