2021-08-31 11:18:20 +02:00
|
|
|
/*
|
|
|
|
* Unix interface for Win32 syscalls
|
|
|
|
*
|
|
|
|
* Copyright (C) 2021 Alexandre Julliard
|
|
|
|
*
|
|
|
|
* 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
|
|
|
|
*/
|
|
|
|
|
|
|
|
#if 0
|
|
|
|
#pragma makedep unix
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <stdarg.h>
|
|
|
|
|
|
|
|
#include "ntstatus.h"
|
|
|
|
#define WIN32_NO_STATUS
|
|
|
|
#include "windef.h"
|
|
|
|
#include "winnt.h"
|
2021-10-06 16:20:35 +02:00
|
|
|
#include "ntgdi_private.h"
|
2021-10-12 16:42:35 +02:00
|
|
|
#include "ntuser.h"
|
2021-08-31 11:18:20 +02:00
|
|
|
#include "wine/unixlib.h"
|
|
|
|
|
|
|
|
|
|
|
|
static void * const syscalls[] =
|
|
|
|
{
|
2021-10-11 18:49:36 +02:00
|
|
|
NtGdiAddFontMemResourceEx,
|
|
|
|
NtGdiAddFontResourceW,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiCombineRgn,
|
2021-10-11 18:48:15 +02:00
|
|
|
NtGdiCreateBitmap,
|
2021-10-11 18:50:09 +02:00
|
|
|
NtGdiCreateClientObj,
|
2021-10-08 13:35:41 +02:00
|
|
|
NtGdiCreateDIBBrush,
|
2021-10-11 18:48:15 +02:00
|
|
|
NtGdiCreateDIBSection,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiCreateEllipticRgn,
|
2021-10-11 18:51:06 +02:00
|
|
|
NtGdiCreateHalftonePalette,
|
2021-10-08 13:35:41 +02:00
|
|
|
NtGdiCreateHatchBrushInternal,
|
2021-10-11 18:51:06 +02:00
|
|
|
NtGdiCreatePaletteInternal,
|
2021-10-08 13:35:41 +02:00
|
|
|
NtGdiCreatePatternBrushInternal,
|
2021-10-12 15:29:19 +02:00
|
|
|
NtGdiCreatePen,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiCreateRectRgn,
|
|
|
|
NtGdiCreateRoundRectRgn,
|
2021-10-08 13:35:41 +02:00
|
|
|
NtGdiCreateSolidBrush,
|
2021-10-11 18:50:09 +02:00
|
|
|
NtGdiDeleteClientObj,
|
2021-10-11 18:49:07 +02:00
|
|
|
NtGdiDescribePixelFormat,
|
|
|
|
NtGdiDrawStream,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiEqualRgn,
|
2021-10-12 15:29:19 +02:00
|
|
|
NtGdiExtCreatePen,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiExtCreateRegion,
|
2021-10-11 18:50:09 +02:00
|
|
|
NtGdiExtGetObjectW,
|
2021-10-12 15:28:52 +02:00
|
|
|
NtGdiFlattenPath,
|
2021-08-31 11:18:20 +02:00
|
|
|
NtGdiFlush,
|
2021-10-11 18:48:15 +02:00
|
|
|
NtGdiGetBitmapBits,
|
|
|
|
NtGdiGetBitmapDimension,
|
2021-10-11 18:50:09 +02:00
|
|
|
NtGdiGetColorAdjustment,
|
|
|
|
NtGdiGetDCObject,
|
2021-10-11 18:49:36 +02:00
|
|
|
NtGdiGetFontFileData,
|
|
|
|
NtGdiGetFontFileInfo,
|
2021-10-11 18:51:06 +02:00
|
|
|
NtGdiGetNearestPaletteIndex,
|
2021-10-12 15:28:52 +02:00
|
|
|
NtGdiGetPath,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiGetRegionData,
|
|
|
|
NtGdiGetRgnBox,
|
2021-10-12 15:30:00 +02:00
|
|
|
NtGdiGetSpoolMessage,
|
2021-10-11 18:51:06 +02:00
|
|
|
NtGdiGetSystemPaletteUse,
|
2021-10-11 18:49:07 +02:00
|
|
|
NtGdiGetTransform,
|
2021-10-11 18:49:36 +02:00
|
|
|
NtGdiHfontCreate,
|
2021-10-12 15:30:00 +02:00
|
|
|
NtGdiInitSpool,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiOffsetRgn,
|
2021-10-12 15:28:52 +02:00
|
|
|
NtGdiPathToRegion,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiPtInRegion,
|
|
|
|
NtGdiRectInRegion,
|
2021-10-11 18:49:36 +02:00
|
|
|
NtGdiRemoveFontMemResourceEx,
|
|
|
|
NtGdiRemoveFontResourceW,
|
2021-10-11 18:49:07 +02:00
|
|
|
NtGdiSaveDC,
|
2021-10-11 18:48:15 +02:00
|
|
|
NtGdiSetBitmapBits,
|
|
|
|
NtGdiSetBitmapDimension,
|
2021-10-11 18:49:07 +02:00
|
|
|
NtGdiSetBrushOrg,
|
2021-10-11 18:50:09 +02:00
|
|
|
NtGdiSetColorAdjustment,
|
2021-10-11 18:51:06 +02:00
|
|
|
NtGdiSetMagicColors,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiSetMetaRgn,
|
2021-10-11 18:49:07 +02:00
|
|
|
NtGdiSetPixelFormat,
|
2021-10-11 18:48:44 +02:00
|
|
|
NtGdiSetRectRgn,
|
2021-10-11 18:49:36 +02:00
|
|
|
NtGdiSetTextJustification,
|
2021-10-11 18:50:37 +02:00
|
|
|
NtGdiSetVirtualResolution,
|
2021-10-11 18:49:07 +02:00
|
|
|
NtGdiSwapBuffers,
|
2021-10-11 18:50:37 +02:00
|
|
|
NtGdiTransformPoints,
|
2021-10-13 14:53:36 +02:00
|
|
|
NtUserCloseDesktop,
|
2021-10-12 16:42:35 +02:00
|
|
|
NtUserCloseWindowStation,
|
2021-10-13 14:52:53 +02:00
|
|
|
NtUserGetProcessWindowStation,
|
2021-10-13 14:53:22 +02:00
|
|
|
NtUserSetProcessWindowStation,
|
2021-08-31 11:18:20 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
static BYTE arguments[ARRAY_SIZE(syscalls)];
|
|
|
|
|
|
|
|
static SYSTEM_SERVICE_TABLE syscall_table =
|
|
|
|
{
|
|
|
|
(ULONG_PTR *)syscalls,
|
|
|
|
0,
|
|
|
|
ARRAY_SIZE(syscalls),
|
|
|
|
arguments
|
|
|
|
};
|
|
|
|
|
|
|
|
static NTSTATUS init( void *dispatcher )
|
|
|
|
{
|
2021-10-06 16:20:35 +02:00
|
|
|
NTSTATUS status;
|
|
|
|
if ((status = ntdll_init_syscalls( 1, &syscall_table, dispatcher ))) return status;
|
|
|
|
return gdi_init();
|
2021-08-31 11:18:20 +02:00
|
|
|
}
|
|
|
|
|
2021-10-06 16:20:35 +02:00
|
|
|
unixlib_entry_t __wine_unix_call_funcs[] =
|
|
|
|
{
|
|
|
|
init,
|
|
|
|
callbacks_init,
|
|
|
|
};
|