Commit 21c99970 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

conhost: Implement IOCTL_CONDRV_SET_MODE.

parent e5bd1ba4
......@@ -3971,6 +3971,16 @@ static void test_pseudo_console_child(HANDLE input, HANDLE output)
ok(ret, "GetConsoleMode failed: %u\n", GetLastError());
ok(mode == (ENABLE_PROCESSED_OUTPUT | ENABLE_WRAP_AT_EOL_OUTPUT), "mode = %x\n", mode);
ret = SetConsoleMode(output, mode & ~ENABLE_WRAP_AT_EOL_OUTPUT);
ok(ret, "SetConsoleMode failed: %u\n", GetLastError());
ret = GetConsoleMode(output, &mode);
ok(ret, "GetConsoleMode failed: %u\n", GetLastError());
ok(mode == ENABLE_PROCESSED_OUTPUT, "mode = %x\n", mode);
ret = SetConsoleMode(output, mode | ENABLE_WRAP_AT_EOL_OUTPUT);
ok(ret, "SetConsoleMode failed: %u\n", GetLastError());
test_console_title();
test_WriteConsoleInputW(input);
}
......
......@@ -244,6 +244,12 @@ static NTSTATUS screen_buffer_ioctl( struct screen_buffer *screen_buffer, unsign
return STATUS_SUCCESS;
}
case IOCTL_CONDRV_SET_MODE:
if (in_size != sizeof(unsigned int) || *out_size) return STATUS_INVALID_PARAMETER;
screen_buffer->mode = *(unsigned int *)in_data;
TRACE( "set %x mode\n", screen_buffer->mode );
return STATUS_SUCCESS;
default:
FIXME( "unsupported ioctl %x\n", code );
return STATUS_NOT_SUPPORTED;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment