From c32169c1c8b50ac828f9380956877c39691c5d0f Mon Sep 17 00:00:00 2001 From: Eric Pouech Date: Sat, 24 Jun 2000 17:54:07 +0000 Subject: [PATCH] A few missing console stubs. --- dlls/kernel/kernel32.spec | 16 ++--- win32/console.c | 133 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 141 insertions(+), 8 deletions(-) diff --git a/dlls/kernel/kernel32.spec b/dlls/kernel/kernel32.spec index 44bbfb0a67..02ee3d75bd 100644 --- a/dlls/kernel/kernel32.spec +++ b/dlls/kernel/kernel32.spec @@ -586,11 +586,11 @@ import ntdll.dll 568 stdcall ReadConsoleA(long ptr long ptr ptr) ReadConsoleA 569 stdcall ReadConsoleInputA(long ptr long ptr) ReadConsoleInputA 570 stdcall ReadConsoleInputW(long ptr long ptr) ReadConsoleInputW -571 stub ReadConsoleOutputA -572 stub ReadConsoleOutputAttribute +571 stdcall ReadConsoleOutputA(long ptr long long ptr) ReadConsoleOutputA +572 stdcall ReadConsoleOutputAttribute(long ptr long long ptr) ReadConsoleOutputAttribute 573 stdcall ReadConsoleOutputCharacterA(long ptr long long ptr) ReadConsoleOutputCharacterA -574 stub ReadConsoleOutputCharacterW -575 stub ReadConsoleOutputW +574 stdcall ReadConsoleOutputCharacterW(long ptr long long ptr) ReadConsoleOutputCharacterW +575 stdcall ReadConsoleOutputW(long ptr long long ptr) ReadConsoleOutputW 576 stdcall ReadConsoleW(long ptr long ptr ptr) ReadConsoleW 577 stdcall ReadFile(long ptr long ptr ptr) ReadFile 578 stdcall ReadFileEx(long ptr long ptr ptr) ReadFileEx @@ -628,7 +628,7 @@ import ntdll.dll 610 register SUnMapLS_IP_EBP_40() SUnMapLS_IP_EBP_40 611 register SUnMapLS_IP_EBP_8() SUnMapLS_IP_EBP_8 612 stdcall ScrollConsoleScreenBufferA(long ptr ptr ptr ptr) ScrollConsoleScreenBufferA -613 stub ScrollConsoleScreenBufferW +613 stdcall ScrollConsoleScreenBufferW(long ptr ptr ptr ptr) ScrollConsoleScreenBufferW 614 stdcall SearchPathA(str str str long ptr ptr) SearchPathA 615 stdcall SearchPathW(wstr wstr wstr long ptr ptr) SearchPathW 616 stdcall SetCommBreak(long) SetCommBreak @@ -639,7 +639,7 @@ import ntdll.dll 621 stdcall SetComputerNameA(str) SetComputerNameA 622 stdcall SetComputerNameW(wstr) SetComputerNameW 623 stdcall SetConsoleActiveScreenBuffer(long) SetConsoleActiveScreenBuffer -624 stub SetConsoleCP +624 stdcall SetConsoleCP(long) SetConsoleCP 625 stdcall SetConsoleCtrlHandler(ptr long) SetConsoleCtrlHandler 626 stdcall SetConsoleCursorInfo(long ptr) SetConsoleCursorInfo 627 stdcall SetConsoleCursorPosition(long long) SetConsoleCursorPosition @@ -746,12 +746,12 @@ import ntdll.dll 728 stdcall WinExec(str long) WinExec 729 stdcall WriteConsoleA(long ptr long ptr ptr) WriteConsoleA 730 stdcall WriteConsoleInputA(long ptr long ptr) WriteConsoleInputA -731 stub WriteConsoleInputW +731 stdcall WriteConsoleInputW(long ptr long ptr) WriteConsoleInputW 732 stdcall WriteConsoleOutputA(long ptr long long ptr) WriteConsoleOutputA 733 stub WriteConsoleOutputAttribute 734 stub WriteConsoleOutputCharacterA 735 stub WriteConsoleOutputCharacterW -736 stub WriteConsoleOutputW +736 stdcall WriteConsoleOutputW(long ptr long long ptr) WriteConsoleOutputW 737 stdcall WriteConsoleW(long ptr long ptr ptr) WriteConsoleW 738 stdcall WriteFile(long ptr long ptr ptr) WriteFile 739 stub WriteFileEx diff --git a/win32/console.c b/win32/console.c index 5687f2c0eb..0127d06f94 100644 --- a/win32/console.c +++ b/win32/console.c @@ -865,6 +865,22 @@ BOOL WINAPI WriteConsoleOutputA( HANDLE hConsoleOutput, return TRUE; } +/*********************************************************************** + * WriteConsoleOutputW (KERNEL32.734) + */ +BOOL WINAPI WriteConsoleOutputW( HANDLE hConsoleOutput, + LPCHAR_INFO lpBuffer, + COORD dwBufferSize, + COORD dwBufferCoord, + LPSMALL_RECT lpWriteRegion) +{ + FIXME("(%d,%p,%dx%d,%dx%d,%p): stub\n", hConsoleOutput, lpBuffer, + dwBufferSize.X,dwBufferSize.Y,dwBufferCoord.X,dwBufferCoord.Y,lpWriteRegion); + + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + /*********************************************************************** * WriteConsoleW (KERNEL32.577) */ @@ -1083,6 +1099,19 @@ BOOL WINAPI WriteConsoleInputA( HANDLE handle, INPUT_RECORD *buffer, return TRUE; } +/****************************************************************************** + * WriteConsoleInputW [KERNEL32.731] Write data to a console input buffer + * + */ +BOOL WINAPI WriteConsoleInputW( HANDLE handle, INPUT_RECORD *buffer, + DWORD count, LPDWORD written ) +{ + FIXME("(%d,%p,%ld,%p): stub!\n", handle, buffer, count, written); + + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + /*********************************************************************** * SetConsoleTitleA (KERNEL32.476) @@ -1427,6 +1456,21 @@ BOOL WINAPI ReadConsoleOutputCharacterA(HANDLE hConsoleOutput, return FALSE; } +/****************************************************************************** + * ReadConsoleOutputCharacterW [KERNEL32.574] + * + * BUGS + * Unimplemented + */ +BOOL WINAPI ReadConsoleOutputCharacterW(HANDLE hConsoleOutput, + LPWSTR lpstr, DWORD dword, COORD coord, LPDWORD lpdword) +{ + FIXME("(%d,%p,%ld,%dx%d,%p): stub\n", hConsoleOutput,lpstr, + dword,coord.X,coord.Y,lpdword); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + /****************************************************************************** * ScrollConsoleScreenBufferA [KERNEL32.612] @@ -1443,3 +1487,92 @@ BOOL WINAPI ScrollConsoleScreenBufferA( HANDLE hConsoleOutput, SetLastError(ERROR_CALL_NOT_IMPLEMENTED); return FALSE; } + +/****************************************************************************** + * ScrollConsoleScreenBufferW [KERNEL32.613] + * + * BUGS + * Unimplemented + */ +BOOL WINAPI ScrollConsoleScreenBufferW( HANDLE hConsoleOutput, + LPSMALL_RECT lpScrollRect, LPSMALL_RECT lpClipRect, + COORD dwDestOrigin, LPCHAR_INFO lpFill) +{ + FIXME("(%d,%p,%p,%dx%d,%p): stub\n", hConsoleOutput,lpScrollRect, + lpClipRect,dwDestOrigin.X,dwDestOrigin.Y,lpFill); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + +/****************************************************************************** + * ReadConsoleOutputA [KERNEL32.571] + * + * BUGS + * Unimplemented + */ +BOOL WINAPI ReadConsoleOutputA( HANDLE hConsoleOutput, + LPCHAR_INFO lpBuffer, + COORD dwBufferSize, + COORD dwBufferCoord, + LPSMALL_RECT lpReadRegion ) +{ + FIXME("(%d,%p,%dx%d,%dx%d,%p): stub\n", hConsoleOutput, lpBuffer, + dwBufferSize.X, dwBufferSize.Y, dwBufferSize.X, dwBufferSize.Y, + lpReadRegion); + + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + +/****************************************************************************** + * ReadConsoleOutputW [KERNEL32.575] + * + * BUGS + * Unimplemented + */ +BOOL WINAPI ReadConsoleOutputW( HANDLE hConsoleOutput, + LPCHAR_INFO lpBuffer, + COORD dwBufferSize, + COORD dwBufferCoord, + LPSMALL_RECT lpReadRegion ) +{ + FIXME("(%d,%p,%dx%d,%dx%d,%p): stub\n", hConsoleOutput, lpBuffer, + dwBufferSize.X, dwBufferSize.Y, dwBufferSize.X, dwBufferSize.Y, + lpReadRegion); + + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + +/****************************************************************************** + * ReadConsoleOutputAttribute [KERNEL32.572] + * + * BUGS + * Unimplemented + */ +BOOL WINAPI ReadConsoleOutputAttribute( HANDLE hConsoleOutput, + LPWORD lpAttribute, + DWORD nLength, + COORD dwReadCoord, + LPDWORD lpNumberOfAttrsRead) +{ + FIXME("(%d,%p,%ld,%dx%d,%p): stub\n", hConsoleOutput, lpAttribute, + nLength, dwReadCoord.X, dwReadCoord.Y, lpNumberOfAttrsRead); + + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + +/****************************************************************************** + * SetConsoleCP [KERNEL32.572] + * + * BUGS + * Unimplemented + */ +BOOL WINAPI SetConsoleCP( UINT cp ) +{ + FIXME("(%d): stub\n", cp); + + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +}