removed WinRT support.

This commit is contained in:
Ozkan Sezer 2022-11-22 23:36:24 +03:00
parent bd5d26071a
commit dc2a3e06e9
86 changed files with 81 additions and 8098 deletions

View file

@ -20,7 +20,7 @@
*/
#include "./SDL_internal.h"
#if defined(__WIN32__) || defined(__WINRT__) || defined(__GDK__)
#if defined(__WIN32__) || defined(__GDK__)
#include "core/windows/SDL_windows.h"
#endif
@ -366,7 +366,7 @@ SDL_LogMessageV(int category, SDL_LogPriority priority, const char *fmt, va_list
}
}
#if defined(__WIN32__) && !defined(HAVE_STDIO_H) && !defined(__WINRT__) && !defined(__GDK__)
#if defined(__WIN32__) && !defined(HAVE_STDIO_H) && !defined(__GDK__)
/* Flag tracking the attachment of the console: 0=unattached, 1=attached to a console, 2=attached to a file, -1=error */
static int consoleAttached = 0;
@ -378,7 +378,7 @@ static void SDLCALL
SDL_LogOutput(void *userdata, int category, SDL_LogPriority priority,
const char *message)
{
#if defined(__WIN32__) || defined(__WINRT__) || defined(__GDK__)
#if defined(__WIN32__) || defined(__GDK__)
/* Way too many allocations here, urgh */
/* Note: One can't call SDL_SetError here, since that function itself logs. */
{
@ -387,7 +387,7 @@ SDL_LogOutput(void *userdata, int category, SDL_LogPriority priority,
LPTSTR tstr;
SDL_bool isstack;
#if !defined(HAVE_STDIO_H) && !defined(__WINRT__) && !defined(__GDK__)
#if !defined(HAVE_STDIO_H) && !defined(__GDK__)
BOOL attachResult;
DWORD attachError;
DWORD charsWritten;
@ -426,7 +426,7 @@ SDL_LogOutput(void *userdata, int category, SDL_LogPriority priority,
}
}
}
#endif /* !defined(HAVE_STDIO_H) && !defined(__WINRT__) && !defined(__GDK__) */
#endif /* !defined(HAVE_STDIO_H) && !defined(__GDK__) */
length = SDL_strlen(SDL_priority_prefixes[priority]) + 2 + SDL_strlen(message) + 1 + 1 + 1;
output = SDL_small_alloc(char, length, &isstack);
@ -436,7 +436,7 @@ SDL_LogOutput(void *userdata, int category, SDL_LogPriority priority,
/* Output to debugger */
OutputDebugString(tstr);
#if !defined(HAVE_STDIO_H) && !defined(__WINRT__) && !defined(__GDK__)
#if !defined(HAVE_STDIO_H) && !defined(__GDK__)
/* Screen output to stderr, if console was attached. */
if (consoleAttached == 1) {
if (!WriteConsole(stderrHandle, tstr, (DWORD) SDL_tcslen(tstr), &charsWritten, NULL)) {
@ -451,7 +451,7 @@ SDL_LogOutput(void *userdata, int category, SDL_LogPriority priority,
OutputDebugString(TEXT("Error calling WriteFile\r\n"));
}
}
#endif /* !defined(HAVE_STDIO_H) && !defined(__WINRT__) && !defined(__GDK__) */
#endif /* !defined(HAVE_STDIO_H) && !defined(__GDK__) */
SDL_free(tstr);
SDL_small_free(output, isstack);