35 lines
885 B
C++
35 lines
885 B
C++
#pragma once
|
|
|
|
#include <XCEngine/UI/DrawData.h>
|
|
|
|
#include <string_view>
|
|
#include <vector>
|
|
|
|
namespace XCEngine::UI::Editor::App {
|
|
|
|
class EditorContext;
|
|
|
|
struct EditorUtilityWindowHostContext {
|
|
bool mounted = false;
|
|
::XCEngine::UI::UIRect bounds = {};
|
|
bool allowInteraction = false;
|
|
bool focused = false;
|
|
bool focusGained = false;
|
|
bool focusLost = false;
|
|
};
|
|
|
|
class EditorUtilityWindowPanel {
|
|
public:
|
|
virtual ~EditorUtilityWindowPanel() = default;
|
|
|
|
virtual std::string_view GetDrawListId() const = 0;
|
|
virtual void ResetInteractionState() = 0;
|
|
virtual void Update(
|
|
EditorContext& context,
|
|
const EditorUtilityWindowHostContext& hostContext,
|
|
const std::vector<::XCEngine::UI::UIInputEvent>& inputEvents) = 0;
|
|
virtual void Append(::XCEngine::UI::UIDrawList& drawList) const = 0;
|
|
};
|
|
|
|
} // namespace XCEngine::UI::Editor::App
|