feat(new_editor): add standalone add-component utility window

This commit is contained in:
2026-04-22 22:07:02 +08:00
parent 865a35e4d0
commit 3048c7cc90
37 changed files with 1237 additions and 290 deletions

View File

@@ -0,0 +1,26 @@
#include "State/EditorUtilityWindowRequestState.h"
namespace XCEngine::UI::Editor::App {
void ResetEditorUtilityWindowRequestState(EditorUtilityWindowRequestState& state) {
state = {};
}
void RequestEditorUtilityWindow(
EditorUtilityWindowRequestState& state,
EditorUtilityWindowKind kind) {
if (kind == EditorUtilityWindowKind::None) {
return;
}
state.pendingKind = kind;
}
std::optional<EditorUtilityWindowKind> ConsumeEditorUtilityWindowRequest(
EditorUtilityWindowRequestState& state) {
const std::optional<EditorUtilityWindowKind> requestedKind = state.pendingKind;
state.pendingKind.reset();
return requestedKind;
}
} // namespace XCEngine::UI::Editor::App