Files
Aerofoil/GpD3D/GpFileSystem_Win32.h
2019-11-11 00:11:59 -05:00

26 lines
703 B
C++

#pragma once
#include "HostFileSystem.h"
#include "GpCoreDefs.h"
#include <string>
class GpFileSystem_Win32 final : public PortabilityLayer::HostFileSystem
{
public:
GpFileSystem_Win32();
bool FileExists(PortabilityLayer::EVirtualDirectory virtualDirectory, const char *path) override;
PortabilityLayer::IOStream *OpenFile(PortabilityLayer::EVirtualDirectory virtualDirectory, const char *path, bool writeAccess, bool create) override;
static GpFileSystem_Win32 *GetInstance();
private:
bool ResolvePath(PortabilityLayer::EVirtualDirectory virtualDirectory, const char *path, wchar_t *outPath);
std::wstring m_prefsDir;
static GpFileSystem_Win32 ms_instance;
};