2 * console-win32-uwp.c: UWP console support for Mono.
4 * Copyright 2016 Microsoft
5 * Licensed under the MIT license. See LICENSE file in the project root for full license information.
9 #include "mono/utils/mono-compiler.h"
11 #if G_HAVE_API_SUPPORT(HAVE_UWP_WINAPI_SUPPORT)
13 #include "mono/metadata/console-win32-internals.h"
16 ves_icall_System_ConsoleDriver_Isatty (HANDLE handle)
19 error_init (&mono_error);
21 g_unsupported_api ("Console");
23 mono_error_set_not_supported (&mono_error, G_UNSUPPORTED_API, "Console");
24 mono_error_set_pending_exception (&mono_error);
26 SetLastError (ERROR_NOT_SUPPORTED);
32 ves_icall_System_ConsoleDriver_SetEcho (MonoBoolean want_echo)
35 error_init (&mono_error);
37 g_unsupported_api ("Console");
39 mono_error_set_not_supported (&mono_error, G_UNSUPPORTED_API, "Console");
40 mono_error_set_pending_exception (&mono_error);
42 SetLastError (ERROR_NOT_SUPPORTED);
48 ves_icall_System_ConsoleDriver_SetBreak (MonoBoolean want_break)
51 error_init (&mono_error);
53 g_unsupported_api ("Console");
55 mono_error_set_not_supported (&mono_error, G_UNSUPPORTED_API, "Console");
56 mono_error_set_pending_exception (&mono_error);
58 SetLastError (ERROR_NOT_SUPPORTED);
64 ves_icall_System_ConsoleDriver_InternalKeyAvailable (gint32 timeout)
67 error_init (&mono_error);
69 g_unsupported_api ("Console");
71 mono_error_set_not_supported (&mono_error, G_UNSUPPORTED_API, "Console");
72 mono_error_set_pending_exception (&mono_error);
74 SetLastError (ERROR_NOT_SUPPORTED);
80 ves_icall_System_ConsoleDriver_TtySetup (MonoString *keypad, MonoString *teardown, MonoArray **control_chars, int **size)
83 error_init (&mono_error);
85 g_unsupported_api ("Console");
87 mono_error_set_not_supported (&mono_error, G_UNSUPPORTED_API, "Console");
88 mono_error_set_pending_exception (&mono_error);
90 SetLastError (ERROR_NOT_SUPPORTED);
95 #else /* G_HAVE_API_SUPPORT(HAVE_UWP_WINAPI_SUPPORT) */
97 MONO_EMPTY_SOURCE_FILE (console_win32_uwp);
98 #endif /* G_HAVE_API_SUPPORT(HAVE_UWP_WINAPI_SUPPORT) */