Add XCUI new editor sandbox phase 1

This commit is contained in:
2026-04-05 04:55:25 +08:00
parent e23f469e5a
commit 67a28bdd4a
76 changed files with 14671 additions and 3 deletions

View File

@@ -0,0 +1,44 @@
#include "Panel.h"
#include <utility>
namespace XCEngine {
namespace NewEditor {
Panel::Panel(std::string name, bool visible)
: m_name(std::move(name))
, m_visible(visible) {
}
Panel::~Panel() = default;
const std::string& Panel::GetName() const {
return m_name;
}
void Panel::SetName(const std::string& name) {
m_name = name;
}
bool Panel::IsVisible() const {
return m_visible;
}
void Panel::SetVisible(bool visible) {
m_visible = visible;
}
void Panel::ToggleVisible() {
m_visible = !m_visible;
}
void Panel::RenderIfVisible() {
if (!m_visible) {
return;
}
Render();
}
} // namespace NewEditor
} // namespace XCEngine