server: Introduce IOCTL_CONDRV_FILL_OUTPUT ioctl.
Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
e20756e9b8
commit
6b96e0e0cb
|
@ -36,6 +36,7 @@
|
||||||
/* console output ioctls */
|
/* console output ioctls */
|
||||||
#define IOCTL_CONDRV_GET_OUTPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 32, METHOD_BUFFERED, FILE_READ_PROPERTIES)
|
#define IOCTL_CONDRV_GET_OUTPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 32, METHOD_BUFFERED, FILE_READ_PROPERTIES)
|
||||||
#define IOCTL_CONDRV_SET_OUTPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 33, METHOD_BUFFERED, FILE_WRITE_PROPERTIES)
|
#define IOCTL_CONDRV_SET_OUTPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 33, METHOD_BUFFERED, FILE_WRITE_PROPERTIES)
|
||||||
|
#define IOCTL_CONDRV_FILL_OUTPUT CTL_CODE(FILE_DEVICE_CONSOLE, 35, METHOD_BUFFERED, FILE_WRITE_DATA)
|
||||||
|
|
||||||
/* console renderer ioctls */
|
/* console renderer ioctls */
|
||||||
#define IOCTL_CONDRV_GET_RENDERER_EVENTS CTL_CODE(FILE_DEVICE_CONSOLE, 70, METHOD_BUFFERED, FILE_READ_PROPERTIES)
|
#define IOCTL_CONDRV_GET_RENDERER_EVENTS CTL_CODE(FILE_DEVICE_CONSOLE, 70, METHOD_BUFFERED, FILE_READ_PROPERTIES)
|
||||||
|
@ -80,6 +81,18 @@ struct condrv_output_info_params
|
||||||
struct condrv_output_info info; /* output info */
|
struct condrv_output_info info; /* output info */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/* IOCTL_CONDRV_FILL_OUTPUT params */
|
||||||
|
struct condrv_fill_output_params
|
||||||
|
{
|
||||||
|
int x; /* position where to start writing */
|
||||||
|
int y;
|
||||||
|
int mode; /* char info mode */
|
||||||
|
int count; /* number to write */
|
||||||
|
int wrap; /* wrap around at end of line? */
|
||||||
|
WCHAR ch; /* character to write */
|
||||||
|
unsigned short attr; /* attribute to write */
|
||||||
|
};
|
||||||
|
|
||||||
#define SET_CONSOLE_OUTPUT_INFO_CURSOR_GEOM 0x0001
|
#define SET_CONSOLE_OUTPUT_INFO_CURSOR_GEOM 0x0001
|
||||||
#define SET_CONSOLE_OUTPUT_INFO_CURSOR_POS 0x0002
|
#define SET_CONSOLE_OUTPUT_INFO_CURSOR_POS 0x0002
|
||||||
#define SET_CONSOLE_OUTPUT_INFO_SIZE 0x0004
|
#define SET_CONSOLE_OUTPUT_INFO_SIZE 0x0004
|
||||||
|
|
|
@ -1682,6 +1682,26 @@ static int screen_buffer_ioctl( struct fd *fd, ioctl_code_t code, struct async *
|
||||||
return set_output_info( screen_buffer, params, get_req_data_size() - sizeof(*params) );
|
return set_output_info( screen_buffer, params, get_req_data_size() - sizeof(*params) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case IOCTL_CONDRV_FILL_OUTPUT:
|
||||||
|
{
|
||||||
|
const struct condrv_fill_output_params *params = get_req_data();
|
||||||
|
char_info_t data;
|
||||||
|
DWORD written;
|
||||||
|
if (get_req_data_size() != sizeof(*params) ||
|
||||||
|
(get_reply_max_size() && get_reply_max_size() != sizeof(written)))
|
||||||
|
{
|
||||||
|
set_error( STATUS_INVALID_PARAMETER );
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
data.ch = params->ch;
|
||||||
|
data.attr = params->attr;
|
||||||
|
written = fill_console_output( screen_buffer, data, params->mode,
|
||||||
|
params->x, params->y, params->count, params->wrap );
|
||||||
|
if (written && get_reply_max_size() == sizeof(written))
|
||||||
|
set_reply_data( &written, sizeof(written) );
|
||||||
|
return !get_error();
|
||||||
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
set_error( STATUS_INVALID_HANDLE );
|
set_error( STATUS_INVALID_HANDLE );
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Reference in New Issue