another constant we can get from pywin32

This commit is contained in:
Jean-Paul Calderone 2021-01-11 13:41:48 -05:00
parent 5c6e5970c9
commit 184b9735b5

View File

@ -23,8 +23,12 @@ from win32con import (
from win32file import ( from win32file import (
INVALID_HANDLE_VALUE, INVALID_HANDLE_VALUE,
FILE_TYPE_CHAR,
) )
# This one not exposed by pywin32 as far as I can tell.
FILE_TYPE_REMOTE = 0x8000
# <https://msdn.microsoft.com/en-us/library/windows/desktop/ms687401%28v=vs.85%29.aspx> # <https://msdn.microsoft.com/en-us/library/windows/desktop/ms687401%28v=vs.85%29.aspx>
# BOOL WINAPI WriteConsoleW(HANDLE hOutput, LPWSTR lpBuffer, DWORD nChars, # BOOL WINAPI WriteConsoleW(HANDLE hOutput, LPWSTR lpBuffer, DWORD nChars,
# LPDWORD lpCharsWritten, LPVOID lpReserved); # LPDWORD lpCharsWritten, LPVOID lpReserved);
@ -121,8 +125,6 @@ def initialize():
use_last_error=True use_last_error=True
)(("GetFileType", windll.kernel32)) )(("GetFileType", windll.kernel32))
FILE_TYPE_CHAR = 0x0002
FILE_TYPE_REMOTE = 0x8000
GetConsoleMode = WINFUNCTYPE( GetConsoleMode = WINFUNCTYPE(
BOOL, HANDLE, POINTER(DWORD), BOOL, HANDLE, POINTER(DWORD),