mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-03 04:13:31 +00:00
[SDK] kernelbase SDK changes
This commit is contained in:
committed by
Justin Miller
parent
a723ff5600
commit
5cef1f68e3
@@ -52,12 +52,20 @@ list(APPEND PCH_SKIP_SOURCE
|
||||
${CMAKE_CURRENT_BINARY_DIR}/svcctl_c.c
|
||||
${CMAKE_CURRENT_BINARY_DIR}/winreg_c.c)
|
||||
|
||||
add_custom_target(advapi32_rpc_headers DEPENDS
|
||||
${CMAKE_CURRENT_BINARY_DIR}/eventlogrpc_c.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/lsa_c.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/seclogon_c.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/svcctl_c.h
|
||||
${CMAKE_CURRENT_BINARY_DIR}/winreg_c.h)
|
||||
|
||||
# This static library is for kernelbase and vista APIs in kernel32
|
||||
add_library(win32_registry
|
||||
${PCH_SKIP_SOURCE}
|
||||
add_library(win32_registry STATIC
|
||||
reg/hkcr.c
|
||||
reg/reg.c
|
||||
)
|
||||
|
||||
add_dependencies(win32_registry advapi32_rpc_headers)
|
||||
target_link_libraries(win32_registry ${PSEH_LIB})
|
||||
target_compile_definitions(win32_registry PRIVATE _KERNEL32_ UNICODE _UNICODE)
|
||||
|
||||
|
||||
@@ -37,6 +37,11 @@ typedef enum AppPolicyWindowingModel
|
||||
AppPolicyWindowingModel_ClassicPhone = 3
|
||||
} AppPolicyWindowingModel;
|
||||
|
||||
typedef enum AppPolicyMediaFoundationCodecLoading
|
||||
{
|
||||
AppPolicyMediaFoundationCodecLoading_All = 0,
|
||||
} AppPolicyMediaFoundationCodecLoading;
|
||||
|
||||
typedef struct PACKAGE_VERSION
|
||||
{
|
||||
union
|
||||
@@ -99,6 +104,15 @@ AppPolicyGetWindowingModel(
|
||||
_In_ HANDLE processToken,
|
||||
_Out_ AppPolicyWindowingModel* policy);
|
||||
|
||||
WINBASEAPI
|
||||
_Check_return_
|
||||
_Success_(return == ERROR_SUCCESS)
|
||||
LONG
|
||||
WINAPI
|
||||
AppPolicyGetMediaFoundationCodecLoading(
|
||||
_In_ HANDLE processToken,
|
||||
_Out_ AppPolicyMediaFoundationCodecLoading* policy);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* Copyright (C) 2023 Paul Gofman for CodeWeavers
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#ifndef __IORINGAPI_H_
|
||||
#define __IORINGAPI_H_
|
||||
|
||||
#include <ntioring_x.h>
|
||||
|
||||
struct IORING_CAPABILITIES
|
||||
{
|
||||
IORING_VERSION MaxVersion;
|
||||
UINT32 MaxSubmissionQueueSize;
|
||||
UINT32 MaxCompletionQueueSize;
|
||||
IORING_FEATURE_FLAGS FeatureFlags;
|
||||
};
|
||||
typedef struct IORING_CAPABILITIES IORING_CAPABILITIES;
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
HRESULT WINAPI QueryIoRingCapabilities(IORING_CAPABILITIES *caps);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
@@ -174,6 +174,20 @@ typedef enum _PROCESS_INFORMATION_CLASS
|
||||
ProcessInformationClassMax
|
||||
} PROCESS_INFORMATION_CLASS;
|
||||
|
||||
#define PROCESS_MACHINE_ATTRIBUTE_KERNEL_ENABLED 0x00000001
|
||||
#define PROCESS_MACHINE_ATTRIBUTE_USER_ENABLED 0x00000002
|
||||
#define PROCESS_MACHINE_ATTRIBUTE_NATIVE_OS 0x00000004
|
||||
#define PROCESS_MACHINE_ATTRIBUTE_WOW64_CONTAINER 0x00000008
|
||||
|
||||
typedef enum _THREAD_INFORMATION_CLASS
|
||||
{
|
||||
ThreadMemoryPriority,
|
||||
ThreadAbsoluteCpuPriority,
|
||||
ThreadDynamicCodePolicy,
|
||||
ThreadPowerThrottling,
|
||||
ThreadInformationClassMax
|
||||
} THREAD_INFORMATION_CLASS;
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
+25
-19
@@ -1105,6 +1105,7 @@ typedef struct _PROC_THREAD_ATTRIBUTE_LIST *PPROC_THREAD_ATTRIBUTE_LIST, *LPPROC
|
||||
#ifndef _USE_FULL_PROC_THREAD_ATTRIBUTE
|
||||
typedef enum _PROC_THREAD_ATTRIBUTE_NUM {
|
||||
ProcThreadAttributeParentProcess = 0,
|
||||
ProcThreadAttributeExtendedFlags = 1,
|
||||
ProcThreadAttributeHandleList = 2,
|
||||
ProcThreadAttributeGroupAffinity = 3,
|
||||
ProcThreadAttributePreferredNode = 4,
|
||||
@@ -1129,10 +1130,26 @@ typedef enum _PROC_THREAD_ATTRIBUTE_NUM {
|
||||
} PROC_THREAD_ATTRIBUTE_NUM;
|
||||
#endif // _USE_FULL_PROC_THREAD_ATTRIBUTE
|
||||
|
||||
#define PROC_THREAD_ATTRIBUTE_IDEAL_PROCESSOR (ProcThreadAttributeIdealProcessor | PROC_THREAD_ATTRIBUTE_THREAD | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_HANDLE_LIST (ProcThreadAttributeHandleList | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_PARENT_PROCESS (ProcThreadAttributeParentProcess | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_EXTENDED_FLAGS (ProcThreadAttributeExtendedFlags | PROC_THREAD_ATTRIBUTE_INPUT | PROC_THREAD_ATTRIBUTE_ADDITIVE)
|
||||
#define PROC_THREAD_ATTRIBUTE_HANDLE_LIST (ProcThreadAttributeHandleList | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_GROUP_AFFINITY (ProcThreadAttributeGroupAffinity | PROC_THREAD_ATTRIBUTE_THREAD | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_PREFERRED_NODE (ProcThreadAttributePreferredNode | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_IDEAL_PROCESSOR (ProcThreadAttributeIdealProcessor | PROC_THREAD_ATTRIBUTE_THREAD | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_UMS_THREAD (ProcThreadAttributeUmsThread | PROC_THREAD_ATTRIBUTE_THREAD | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_MITIGATION_POLICY (ProcThreadAttributeMitigationPolicy | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_SECURITY_CAPABILITIES (ProcThreadAttributeSecurityCapabilities | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_PROTECTION_LEVEL (ProcThreadAttributeProtectionLevel | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_JOB_LIST (ProcThreadAttributeJobList | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY (ProcThreadAttributeChildProcessPolicy | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_ALL_APPLICATION_PACKAGES_POLICY (ProcThreadAttributeAllApplicationPackagesPolicy | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_WIN32K_FILTER (ProcThreadAttributeWin32kFilter | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_DESKTOP_APP_POLICY (ProcThreadAttributeDesktopAppPolicy | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_PSEUDOCONSOLE (ProcThreadAttributePseudoConsole | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_MITIGATION_AUDIT_POLICY (ProcThreadAttributeMitigationAuditPolicy | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_MACHINE_TYPE (ProcThreadAttributeMachineType | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_COMPONENT_FILTER (ProcThreadAttributeComponentFilter | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
#define PROC_THREAD_ATTRIBUTE_ENABLE_OPTIONAL_XSTATE_FEATURES (ProcThreadAttributeEnableOptionalXStateFeatures | PROC_THREAD_ATTRIBUTE_THREAD | PROC_THREAD_ATTRIBUTE_INPUT)
|
||||
|
||||
#if (_WIN32_WINNT >= 0x0600)
|
||||
#define ProcThreadAttributeValue(Number, Thread, Input, Additive) \
|
||||
@@ -1147,23 +1164,6 @@ typedef enum _PROC_THREAD_ATTRIBUTE_NUM {
|
||||
#define PROCESS_CREATION_CHILD_PROCESS_OVERRIDE 0x02
|
||||
#define PROCESS_CREATION_CHILD_PROCESS_RESTRICTED_UNLESS_SECURE 0x04
|
||||
#define PROCESS_CREATION_ALL_APPLICATION_PACKAGES_OPT_OUT 0x01
|
||||
|
||||
#define PROC_THREAD_ATTRIBUTE_JOB_LIST \
|
||||
ProcThreadAttributeValue(ProcThreadAttributeJobList, FALSE, TRUE, FALSE)
|
||||
|
||||
#define PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY \
|
||||
ProcThreadAttributeValue(ProcThreadAttributeChildProcessPolicy, FALSE, TRUE, FALSE)
|
||||
|
||||
#define PROC_THREAD_ATTRIBUTE_ALL_APPLICATION_PACKAGES_POLICY \
|
||||
ProcThreadAttributeValue(ProcThreadAttributeAllApplicationPackagesPolicy, FALSE, TRUE, FALSE)
|
||||
|
||||
#define PROC_THREAD_ATTRIBUTE_WIN32K_FILTER \
|
||||
ProcThreadAttributeValue(ProcThreadAttributeWin32kFilter, FALSE, TRUE, FALSE)
|
||||
#endif //(_WIN32_WINNT >= _WIN32_WINNT_WINTHRESHOLD)
|
||||
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN10_RS5)
|
||||
#define PROC_THREAD_ATTRIBUTE_PSEUDOCONSOLE \
|
||||
ProcThreadAttributeValue(ProcThreadAttributePseudoConsole, FALSE, TRUE, FALSE)
|
||||
#endif //(NTDDI_VERSION >= NTDDI_WIN10_RS5)
|
||||
|
||||
typedef DWORD
|
||||
@@ -3665,6 +3665,12 @@ typedef BOOL
|
||||
_Inout_opt_ PVOID Parameter,
|
||||
_Outptr_opt_result_maybenull_ PVOID *Context);
|
||||
|
||||
|
||||
#define RESOURCE_ENUM_LN 0x0001
|
||||
#define RESOURCE_ENUM_MUI 0x0002
|
||||
#define RESOURCE_ENUM_MUI_SYSTEM 0x0004
|
||||
#define RESOURCE_ENUM_VALIDATE 0x0008
|
||||
|
||||
#if _WIN32_WINNT >= 0x0601
|
||||
|
||||
#define COPYFILE2_MESSAGE_COPY_OFFLOAD 0x00000001L
|
||||
|
||||
@@ -973,12 +973,36 @@ WriteConsoleOutputCharacterW(
|
||||
_Out_ LPDWORD lpNumberOfCharsWritten);
|
||||
|
||||
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN10_RS5)
|
||||
// typedef VOID *HPCON;
|
||||
// CreatePseudoConsole()
|
||||
// ResizePseudoConsole()
|
||||
// ClosePseudoConsole()
|
||||
#endif // (NTDDI_VERSION >= NTDDI_WIN10_RS5)
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN10_RS5) || defined(_KERNELBASE_)
|
||||
|
||||
typedef VOID *HPCON;
|
||||
|
||||
#define PSEUDOCONSOLE_INHERIT_CURSOR 0x00000001
|
||||
|
||||
WINBASEAPI
|
||||
HRESULT
|
||||
WINAPI
|
||||
CreatePseudoConsole(
|
||||
_In_ COORD size,
|
||||
_In_ HANDLE hInput,
|
||||
_In_ HANDLE hOutput,
|
||||
_In_ DWORD dwFlags,
|
||||
_Out_ HPCON *phPC);
|
||||
|
||||
WINBASEAPI
|
||||
void
|
||||
WINAPI
|
||||
ClosePseudoConsole(
|
||||
_In_ HPCON hPC);
|
||||
|
||||
WINBASEAPI
|
||||
HRESULT
|
||||
WINAPI
|
||||
ResizePseudoConsole(
|
||||
_In_ HPCON hPC,
|
||||
_In_ COORD size);
|
||||
|
||||
#endif // (NTDDI_VERSION >= NTDDI_WIN10_RS5) || _KERNELBASE_
|
||||
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN11_GE)
|
||||
/* See https://github.com/microsoft/terminal/blob/main/doc/specs/%237335%20-%20Console%20Allocation%20Policy.md
|
||||
|
||||
@@ -485,13 +485,11 @@ extern "C" {
|
||||
#define CAL_SMONTHDAY 56
|
||||
#define CAL_SABBREVERASTRING 57
|
||||
#endif //(WINVER >= _WIN32_WINNT_WIN7)
|
||||
#if (WINVER >= _WIN32_WINNT_WIN8)
|
||||
#if (WINVER >= _WIN32_WINNT_WIN8) || defined(_KERNELBASE_)
|
||||
#define CAL_SRELATIVELONGDATE 58
|
||||
#endif //(WINVER >= _WIN32_WINNT_WIN8)
|
||||
//#if (NTDDI_VERSION >= NTDDI_WIN10_RS2)
|
||||
#define CAL_SENGLISHERANAME 59
|
||||
#define CAL_SENGLISHABBREVERANAME 60
|
||||
//#endif //(NTDDI_VERSION >= NTDDI_WIN10_RS2)
|
||||
#endif /* WIN8+ or kernelbase Wine build */
|
||||
#define CAL_GREGORIAN 1
|
||||
#define CAL_GREGORIAN_US 2
|
||||
#define CAL_JAPAN 3
|
||||
@@ -543,6 +541,7 @@ extern "C" {
|
||||
#define MAP_EXPAND_LIGATURES 0x2000
|
||||
#define CAL_NOUSEROVERRIDE LOCALE_NOUSEROVERRIDE
|
||||
#define CAL_RETURN_NUMBER LOCALE_RETURN_NUMBER
|
||||
#define CAL_RETURN_GENITIVE_NAMES LOCALE_RETURN_GENITIVE_NAMES
|
||||
#define CAL_USE_CP_ACP LOCALE_USE_CP_ACP
|
||||
#define CAL_RETURN_GENITIVE_NAMES LOCALE_RETURN_GENITIVE_NAMES
|
||||
|
||||
@@ -652,7 +651,7 @@ enum SYSGEOTYPE
|
||||
GEO_DIALINGCODE,
|
||||
GEO_CURRENCYCODE,
|
||||
GEO_CURRENCYSYMBOL,
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN10_RS3)
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN10_RS3) || defined(_KERNELBASE_)
|
||||
GEO_NAME,
|
||||
GEO_ID
|
||||
#endif
|
||||
@@ -703,7 +702,7 @@ typedef struct _nlsversioninfo {
|
||||
DWORD dwNLSVersionInfoSize;
|
||||
DWORD dwNLSVersion;
|
||||
DWORD dwDefinedVersion;
|
||||
#if (WINVER >= _WIN32_WINNT_WIN8)
|
||||
#if (WINVER >= _WIN32_WINNT_WIN8) || defined(_KERNELBASE_)
|
||||
DWORD dwEffectiveId;
|
||||
GUID guidCustomVersion;
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,203 @@
|
||||
/*
|
||||
* Console driver ioctls
|
||||
*
|
||||
* Copyright 2020 Jacek Caban for CodeWeavers
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#ifndef _INC_CONDRV
|
||||
#define _INC_CONDRV
|
||||
|
||||
#include "winioctl.h"
|
||||
#include "wincon.h"
|
||||
|
||||
/* common console input and output ioctls */
|
||||
#define IOCTL_CONDRV_GET_MODE CTL_CODE(FILE_DEVICE_CONSOLE, 0, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_SET_MODE CTL_CODE(FILE_DEVICE_CONSOLE, 1, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_IS_UNIX CTL_CODE(FILE_DEVICE_CONSOLE, 2, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
|
||||
/* console input ioctls */
|
||||
#define IOCTL_CONDRV_READ_CONSOLE CTL_CODE(FILE_DEVICE_CONSOLE, 10, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_READ_FILE CTL_CODE(FILE_DEVICE_CONSOLE, 11, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_READ_INPUT CTL_CODE(FILE_DEVICE_CONSOLE, 12, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_WRITE_INPUT CTL_CODE(FILE_DEVICE_CONSOLE, 13, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_PEEK CTL_CODE(FILE_DEVICE_CONSOLE, 14, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_GET_INPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 15, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_SET_INPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 16, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_GET_TITLE CTL_CODE(FILE_DEVICE_CONSOLE, 17, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_SET_TITLE CTL_CODE(FILE_DEVICE_CONSOLE, 18, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_CTRL_EVENT CTL_CODE(FILE_DEVICE_CONSOLE, 19, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
#define IOCTL_CONDRV_BEEP CTL_CODE(FILE_DEVICE_CONSOLE, 20, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
#define IOCTL_CONDRV_FLUSH CTL_CODE(FILE_DEVICE_CONSOLE, 21, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
#define IOCTL_CONDRV_GET_WINDOW CTL_CODE(FILE_DEVICE_CONSOLE, 22, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
#define IOCTL_CONDRV_GET_PROCESS_LIST CTL_CODE(FILE_DEVICE_CONSOLE, 23, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
#define IOCTL_CONDRV_READ_CONSOLE_CONTROL CTL_CODE(FILE_DEVICE_CONSOLE, 24, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_GET_INPUT_COUNT CTL_CODE(FILE_DEVICE_CONSOLE, 25, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
|
||||
/* console output ioctls */
|
||||
#define IOCTL_CONDRV_WRITE_CONSOLE CTL_CODE(FILE_DEVICE_CONSOLE, 30, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_WRITE_FILE CTL_CODE(FILE_DEVICE_CONSOLE, 31, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_READ_OUTPUT CTL_CODE(FILE_DEVICE_CONSOLE, 32, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_WRITE_OUTPUT CTL_CODE(FILE_DEVICE_CONSOLE, 33, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_GET_OUTPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 34, METHOD_BUFFERED, FILE_READ_ACCESS)
|
||||
#define IOCTL_CONDRV_SET_OUTPUT_INFO CTL_CODE(FILE_DEVICE_CONSOLE, 35, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_ACTIVATE CTL_CODE(FILE_DEVICE_CONSOLE, 36, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_FILL_OUTPUT CTL_CODE(FILE_DEVICE_CONSOLE, 37, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
#define IOCTL_CONDRV_SCROLL CTL_CODE(FILE_DEVICE_CONSOLE, 38, METHOD_BUFFERED, FILE_WRITE_ACCESS)
|
||||
|
||||
/* console connection ioctls */
|
||||
#define IOCTL_CONDRV_BIND_PID CTL_CODE(FILE_DEVICE_CONSOLE, 51, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
|
||||
/* console server ioctls */
|
||||
#define IOCTL_CONDRV_SETUP_INPUT CTL_CODE(FILE_DEVICE_CONSOLE, 60, METHOD_BUFFERED, FILE_ANY_ACCESS)
|
||||
|
||||
/* ioctls used for communication between driver and host */
|
||||
#define IOCTL_CONDRV_INIT_OUTPUT CTL_CODE(FILE_DEVICE_CONSOLE, 90, METHOD_BUFFERED, 0)
|
||||
#define IOCTL_CONDRV_CLOSE_OUTPUT CTL_CODE(FILE_DEVICE_CONSOLE, 91, METHOD_BUFFERED, 0)
|
||||
|
||||
/* console handle type */
|
||||
typedef unsigned int condrv_handle_t;
|
||||
|
||||
/* convert an object handle to a server handle */
|
||||
static inline condrv_handle_t condrv_handle( HANDLE handle )
|
||||
{
|
||||
if ((int)(INT_PTR)handle != (INT_PTR)handle) return 0xfffffff0; /* some invalid handle */
|
||||
return (INT_PTR)handle;
|
||||
}
|
||||
|
||||
/* structure for console char/attribute info */
|
||||
typedef struct
|
||||
{
|
||||
WCHAR ch;
|
||||
unsigned short attr;
|
||||
} char_info_t;
|
||||
|
||||
/* IOCTL_CONDRV_GET_INPUT_INFO result */
|
||||
struct condrv_input_info
|
||||
{
|
||||
unsigned int input_cp; /* console input codepage */
|
||||
unsigned int output_cp; /* console output codepage */
|
||||
};
|
||||
|
||||
/* IOCTL_CONDRV_SET_INPUT_INFO params */
|
||||
struct condrv_input_info_params
|
||||
{
|
||||
unsigned int mask; /* setting mask */
|
||||
struct condrv_input_info info; /* input_info */
|
||||
};
|
||||
|
||||
#define SET_CONSOLE_INPUT_INFO_INPUT_CODEPAGE 0x01
|
||||
#define SET_CONSOLE_INPUT_INFO_OUTPUT_CODEPAGE 0x02
|
||||
|
||||
/* IOCTL_CONDRV_WRITE_OUTPUT and IOCTL_CONDRV_READ_OUTPUT params */
|
||||
struct condrv_output_params
|
||||
{
|
||||
unsigned int x; /* destination position */
|
||||
unsigned int y;
|
||||
unsigned int mode; /* char info mode */
|
||||
unsigned int width; /* width of output rectangle, 0 for wrapped mode */
|
||||
/* followed by an array of data with type depending on mode */
|
||||
};
|
||||
|
||||
enum char_info_mode
|
||||
{
|
||||
CHAR_INFO_MODE_TEXT, /* characters only */
|
||||
CHAR_INFO_MODE_ATTR, /* attributes only */
|
||||
CHAR_INFO_MODE_TEXTATTR, /* both characters and attributes */
|
||||
};
|
||||
|
||||
/* IOCTL_CONDRV_GET_OUTPUT_INFO result */
|
||||
struct condrv_output_info
|
||||
{
|
||||
short int cursor_size; /* size of cursor (percentage filled) */
|
||||
short int cursor_visible; /* cursor visibility flag */
|
||||
short int cursor_x; /* position of cursor (x, y) */
|
||||
short int cursor_y;
|
||||
short int width; /* width of the screen buffer */
|
||||
short int height; /* height of the screen buffer */
|
||||
short int attr; /* default fill attributes (screen colors) */
|
||||
short int popup_attr; /* pop-up color attributes */
|
||||
short int win_left; /* window actually displayed by renderer */
|
||||
short int win_top; /* the rect area is expressed within the */
|
||||
short int win_right; /* boundaries of the screen buffer */
|
||||
short int win_bottom;
|
||||
short int max_width; /* maximum size (width x height) for the window */
|
||||
short int max_height;
|
||||
short int font_width; /* font size (width x height) */
|
||||
short int font_height;
|
||||
short int font_weight; /* font weight */
|
||||
short int font_pitch_family; /* font pitch & family */
|
||||
unsigned int color_map[16]; /* color table */
|
||||
};
|
||||
|
||||
/* IOCTL_CONDRV_SET_OUTPUT_INFO params */
|
||||
struct condrv_output_info_params
|
||||
{
|
||||
unsigned int mask; /* setting mask */
|
||||
struct condrv_output_info info; /* output info */
|
||||
};
|
||||
|
||||
#define SET_CONSOLE_OUTPUT_INFO_CURSOR_GEOM 0x0001
|
||||
#define SET_CONSOLE_OUTPUT_INFO_CURSOR_POS 0x0002
|
||||
#define SET_CONSOLE_OUTPUT_INFO_SIZE 0x0004
|
||||
#define SET_CONSOLE_OUTPUT_INFO_ATTR 0x0008
|
||||
#define SET_CONSOLE_OUTPUT_INFO_DISPLAY_WINDOW 0x0010
|
||||
#define SET_CONSOLE_OUTPUT_INFO_MAX_SIZE 0x0020
|
||||
#define SET_CONSOLE_OUTPUT_INFO_POPUP_ATTR 0x0040
|
||||
#define SET_CONSOLE_OUTPUT_INFO_FONT 0x0080
|
||||
|
||||
/* IOCTL_CONDRV_GET_TITLE params */
|
||||
struct condrv_title_params
|
||||
{
|
||||
unsigned int title_len;
|
||||
WCHAR buffer[1];
|
||||
};
|
||||
|
||||
/* 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 */
|
||||
};
|
||||
|
||||
/* IOCTL_CONDRV_SCROLL params */
|
||||
struct condrv_scroll_params
|
||||
{
|
||||
SMALL_RECT scroll; /* source rectangle */
|
||||
COORD origin; /* destination coordinates */
|
||||
SMALL_RECT clip; /* clipping rectangle */
|
||||
char_info_t fill; /* empty character info */
|
||||
};
|
||||
|
||||
/* IOCTL_CONDRV_CTRL_EVENT params */
|
||||
struct condrv_ctrl_event
|
||||
{
|
||||
int event; /* the event to send */
|
||||
unsigned int group_id; /* the group to send the event to */
|
||||
};
|
||||
|
||||
/* Wine specific values for console inheritance (params->ConsoleHandle) */
|
||||
#define CONSOLE_HANDLE_ALLOC LongToHandle(-1)
|
||||
#define CONSOLE_HANDLE_ALLOC_NO_WINDOW LongToHandle(-2)
|
||||
#define CONSOLE_HANDLE_SHELL LongToHandle(-3)
|
||||
#define CONSOLE_HANDLE_SHELL_NO_WINDOW LongToHandle(-4)
|
||||
|
||||
#endif /* _INC_CONDRV */
|
||||
@@ -4796,6 +4796,8 @@ typedef VOID
|
||||
typedef VOID (NTAPI *PTP_TIMER_CALLBACK)(PTP_CALLBACK_INSTANCE,PVOID,PTP_TIMER);
|
||||
typedef VOID (NTAPI *PTP_WAIT_CALLBACK)(PTP_CALLBACK_INSTANCE,PVOID,PTP_WAIT,TP_WAIT_RESULT);
|
||||
|
||||
NTSYSAPI BOOLEAN NTAPI RtlGetProductInfo(DWORD,DWORD,DWORD,DWORD,PDWORD);
|
||||
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN7)
|
||||
typedef struct _TP_CALLBACK_ENVIRON_V3 {
|
||||
TP_VERSION Version;
|
||||
|
||||
Reference in New Issue
Block a user