#pragma once #include #include #include #include namespace XCEngine::UI::Editor::App::Internal { class EditorWindowWorkspaceStore final { public: explicit EditorWindowWorkspaceStore(UIEditorPanelRegistry panelRegistry); const UIEditorPanelRegistry& GetPanelRegistry() const { return m_panelRegistry; } bool HasState() const { return !m_windowSet.windows.empty(); } const UIEditorWindowWorkspaceSet& GetWindowSet() const { return m_windowSet; } UIEditorWindowWorkspaceController BuildMutationController() const; bool RegisterWindowProjection( std::string_view windowId, bool primary, const UIEditorWorkspaceController& workspaceController, std::string& outError); bool CommitWindowProjection( std::string_view windowId, const UIEditorWorkspaceController& workspaceController, std::string& outError); bool ValidateWindowSet( const UIEditorWindowWorkspaceSet& windowSet, std::string& outError) const; void ReplaceWindowSet(UIEditorWindowWorkspaceSet windowSet); void RemoveWindow(std::string_view windowId, bool primary); private: UIEditorPanelRegistry m_panelRegistry = {}; UIEditorWindowWorkspaceSet m_windowSet = {}; }; } // namespace XCEngine::UI::Editor::App::Internal