[nostalgia/scene] ACTUALLY add Scene Studio module

This commit is contained in:
2023-03-11 18:45:35 -06:00
parent 986ee3d7b0
commit 4a95a79926
9 changed files with 294 additions and 0 deletions
@@ -0,0 +1,43 @@
/*
* Copyright 2016 - 2023 Gary Talent (gary@drinkingtea.net). All rights reserved.
*/
#pragma once
#include <nostalgia/core/gfx.hpp>
#include <nostalgia/studio/studio.hpp>
#include "sceneeditor.hpp"
#include "sceneeditorview.hpp"
namespace nostalgia::scene {
class SceneEditorImGui: public studio::Editor {
private:
core::Context *m_ctx = nullptr;
ox::String m_itemName;
ox::String m_itemPath;
SceneEditor m_editor;
SceneEditorView m_view;
public:
SceneEditorImGui(core::Context *ctx, ox::CRStringView path);
/**
* Returns the name of item being edited.
*/
ox::CRString itemName() const noexcept final;
ox::CRString itemDisplayName() const noexcept final;
void draw(core::Context*) noexcept final;
void onActivated() noexcept override;
protected:
ox::Error saveItem() noexcept final;
};
}