载入中...
搜索中...
未找到
ActionEditorPackage.cpp
浏览该文件的文档.
2
4
5namespace eve::action_editor {
6namespace {
7
8editing::PropertySchema actionTargetCreateSchema() {
9 editing::PropertySchema schema;
10 schema.typeId = "action-timeline.create";
11 schema.version = 1;
12 {
13 editing::PropertyDescriptor timeline;
14 timeline.path = editing::PropertyPath("timeline");
15 timeline.displayNameKey = "Timeline snapshot";
16 timeline.type = editing::PropertyType::Struct;
17 timeline.flags = editing::PropertyFlag::Advanced;
18 schema.properties.push_back(std::move(timeline));
19 }
20 {
21 editing::PropertyDescriptor animationUri;
22 animationUri.path = editing::PropertyPath("animationUri");
23 animationUri.displayNameKey = "Animation URI";
24 animationUri.type = editing::PropertyType::AssetRef;
25 schema.properties.push_back(std::move(animationUri));
26 }
27 return schema;
28}
29
30} // namespace
31
34 package.ownerModule = "action_editor";
35 package.selectionDomain = "action.timeline";
36 package.previewKind = "action.timeline.preview";
38 package.incomplete = false;
39 package.panels = {
40 {"action.assets", "Actions", "left", "action.timeline", "list", 100, false},
41 {"action.preview", "Action Preview", "center", "action.timeline", "preview", 100, true},
42 {"action.inspector", "Action Inspector", "right", "action.timeline", "inspector", 100, false},
43 {"action.timeline", "Action Timeline", "bottom", "action.timeline", "timeline", 100, false},
44 };
46 {
48 action.type = "action";
49 action.createSchema = actionTargetCreateSchema();
50 package.targetTypes.push_back(std::move(action));
51 }
52 {
54 timeline.type = "action-timeline";
55 timeline.createSchema = actionTargetCreateSchema();
56 package.targetTypes.push_back(std::move(timeline));
57 }
58 return package;
59}
60
62
63std::string_view ActionEditorPackageProvider::ownerModule() const { return package_.ownerModule; }
64
66
67} // namespace eve::action_editor
std::string action
Definition PlayHost.cpp:118
const editing::EditorPackage & package() const override
Return the advertised package snapshot. @lifetime Borrowed until the provider is destroyed or next mu...
std::string_view ownerModule() const override
Stable owner module identity (matches command ownerModule).
editing::EditorPackage makeActionEditorPackage()
Build the Action editor package snapshot (panels, commands, target types).
editing::EditingCommandDescriptor actionPropertySetCommandDescriptor()
Metadata for the Action property-set command (shared with EditorPackage).
Single domain-editor deliverable for Host discover/autoMount.
EditorUndoPolicy undoPolicy
std::vector< EditorTargetTypeSpec > targetTypes
std::vector< EditingCommandDescriptor > commands
std::vector< EditorPanelSpec > panels
Target type advertised for automation create, with optional createSchema.