Files
IAEngine/Src/Editor/imp/cpp/UI/View/Asset.cpp
Isuru Samarathunga 9d6f525b81 Fixes
2025-11-11 09:24:14 +05:30

69 lines
1.5 KiB
C++

// IAEngine: 2D Game Engine by IA
// Copyright (C) 2025 IASoft (PVT) LTD (oss@iasoft.dev)
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
#include <UI/View/Asset.hpp>
namespace ia::iae
{
struct AssetCacheEntry
{
};
VOID View_Asset::Initialize()
{
SetName("Asset");
SetIcon(ICON_FA_STAR);
}
VOID View_Asset::Terminate()
{
}
VOID View_Asset::Render()
{
PreRender();
if(m_assetPath.empty())
{
PostRender();
return;
}
ImGui::Text("%s", m_assetPath.filename().string().c_str());
PostRender();
}
VOID View_Asset::Update()
{
}
VOID View_Asset::OnEvent(IN SDL_Event *event)
{
}
VOID View_Asset::Open(IN Path path)
{
Close();
m_assetPath = path;
}
VOID View_Asset::Close()
{
m_assetPath = Path();
}
} // namespace ia::iae