Refactor editor host resource boundary
This commit is contained in:
27
editor/app/Host/Win32/Resources/Win32EditorResourceService.h
Normal file
27
editor/app/Host/Win32/Resources/Win32EditorResourceService.h
Normal file
@@ -0,0 +1,27 @@
|
||||
#pragma once
|
||||
|
||||
#ifndef NOMINMAX
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
|
||||
#include "EditorHostResourceService.h"
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
namespace XCEngine::UI::Editor::Host {
|
||||
|
||||
class Win32EditorResourceService final : public EditorHostResourceService {
|
||||
public:
|
||||
explicit Win32EditorResourceService(HINSTANCE instance);
|
||||
|
||||
bool TryLoadPngResource(
|
||||
EditorHostPngResourceKind kind,
|
||||
EditorHostResourceBytes& outBytes,
|
||||
std::string& outError) const override;
|
||||
std::filesystem::path GetExecutableDirectory() const override;
|
||||
|
||||
private:
|
||||
HINSTANCE m_instance = nullptr;
|
||||
};
|
||||
|
||||
} // namespace XCEngine::UI::Editor::Host
|
||||
Reference in New Issue
Block a user