55 lines
1.6 KiB
C++
55 lines
1.6 KiB
C++
#pragma once
|
|
|
|
#include "Features/Inspector/InspectorSubject.h"
|
|
|
|
#include <XCEditor/Fields/UIEditorPropertyGrid.h>
|
|
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
namespace XCEngine::UI::Editor::App {
|
|
|
|
class EditorSceneRuntime;
|
|
class InspectorComponentEditorRegistry;
|
|
|
|
struct InspectorPresentationComponentBinding {
|
|
std::string componentId = {};
|
|
std::string typeName = {};
|
|
std::string displayName = {};
|
|
bool removable = false;
|
|
std::vector<std::string> fieldIds = {};
|
|
};
|
|
|
|
struct InspectorPresentationModel {
|
|
bool hasSelection = false;
|
|
bool showHeader = true;
|
|
std::string title = {};
|
|
std::string subtitle = {};
|
|
std::string structureSignature = {};
|
|
std::vector<Widgets::UIEditorPropertyGridSection> sections = {};
|
|
std::vector<InspectorPresentationComponentBinding> componentBindings = {};
|
|
};
|
|
|
|
struct InspectorPresentationSyncResult {
|
|
bool success = false;
|
|
bool valueChanged = false;
|
|
};
|
|
|
|
InspectorPresentationModel BuildInspectorPresentationModel(
|
|
const InspectorSubject& subject,
|
|
const EditorSceneRuntime& sceneRuntime,
|
|
const InspectorComponentEditorRegistry& componentEditorRegistry);
|
|
|
|
std::string BuildInspectorStructureSignature(
|
|
const InspectorSubject& subject,
|
|
const EditorSceneRuntime& sceneRuntime,
|
|
const InspectorComponentEditorRegistry& componentEditorRegistry);
|
|
|
|
InspectorPresentationSyncResult SyncInspectorPresentationModelValues(
|
|
InspectorPresentationModel& model,
|
|
const InspectorSubject& subject,
|
|
const EditorSceneRuntime& sceneRuntime,
|
|
const InspectorComponentEditorRegistry& componentEditorRegistry);
|
|
|
|
} // namespace XCEngine::UI::Editor::App
|