ttf: ++uwp portability

use the preprocessor directives properly.
This commit is contained in:
Hermet Park 2024-03-22 14:42:32 +09:00 committed by Hermet Park
parent b3f09cab6b
commit 832f22e915
2 changed files with 3 additions and 3 deletions

View file

@ -23,7 +23,7 @@
#include "tvgTtfLoader.h" #include "tvgTtfLoader.h"
#if defined(_WIN32) #if defined(_WIN32) && (WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP)
#include <windows.h> #include <windows.h>
#elif defined(__linux__) #elif defined(__linux__)
#include <fcntl.h> #include <fcntl.h>
@ -36,7 +36,7 @@
/* Internal Class Implementation */ /* Internal Class Implementation */
/************************************************************************/ /************************************************************************/
#if defined(_WIN32) #if defined(_WIN32) && (WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP)
static bool _map(TtfLoader* loader, const string& path) static bool _map(TtfLoader* loader, const string& path)
{ {

View file

@ -30,7 +30,7 @@
struct TtfLoader : public FontLoader struct TtfLoader : public FontLoader
{ {
#if defined(_WIN32) #if defined(_WIN32) && (WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP)
void* mapping = nullptr; void* mapping = nullptr;
#endif #endif
TtfReader reader; TtfReader reader;