diff --git a/reactos/include/ddk/winddi.h b/reactos/include/ddk/winddi.h index 691e4c21167..4525a43384f 100644 --- a/reactos/include/ddk/winddi.h +++ b/reactos/include/ddk/winddi.h @@ -1248,7 +1248,14 @@ EngSetLastError EngSetPointerShape EngSetPointerTag EngSetPrinterData -EngSort +*/ + +typedef int CDECL (*SORTCOMP)(const void *Elem1, const void *Elem2); + +void STDCALL +EngSort(IN OUT PBYTE Buf, IN ULONG ElemSize, IN ULONG ElemCount, IN SORTCOMP CompFunc); + +/* EngStretchBlt EngStrokeAndFillPath EngStrokePath diff --git a/reactos/subsys/win32k/eng/sort.c b/reactos/subsys/win32k/eng/sort.c new file mode 100644 index 00000000000..fd1f2bb30eb --- /dev/null +++ b/reactos/subsys/win32k/eng/sort.c @@ -0,0 +1,33 @@ +/* + * ReactOS W32 Subsystem + * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 ReactOS Team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + */ +/* $Id: sort.c,v 1.1 2003/07/12 12:45:29 gvg Exp $ */ + +#include +#include + +/* + * @implemented + */ +void STDCALL +EngSort(IN OUT PBYTE Buf, IN ULONG ElemSize, IN ULONG ElemCount, IN SORTCOMP CompFunc) +{ + qsort(Buf, ElemSize, ElemCount, CompFunc); +} + +/* EOF */ diff --git a/reactos/subsys/win32k/makefile b/reactos/subsys/win32k/makefile index ff296d6475c..440f2afff19 100644 --- a/reactos/subsys/win32k/makefile +++ b/reactos/subsys/win32k/makefile @@ -1,4 +1,4 @@ -# $Id: makefile,v 1.68 2003/06/21 18:06:11 ekohl Exp $ +# $Id: makefile,v 1.69 2003/07/12 12:45:29 gvg Exp $ PATH_TO_TOP = ../.. @@ -31,12 +31,13 @@ TARGET_CFLAGS =\ TARGET_LFLAGS =\ $(PATH_TO_TOP)/dk/nkm/lib/freetype.a \ + $(PATH_TO_TOP)/dk/w32/lib/rosrtl.a \ --disable-stdcall-fixup ENG_OBJECTS= eng/debug.o eng/mem.o eng/brush.o eng/bitblt.o eng/clip.o \ eng/copybits.o eng/device.o eng/handle.o eng/lineto.o eng/paint.o \ eng/palette.o eng/perfcnt.o eng/surface.o eng/xlate.o eng/transblt.o \ - eng/mouse.o eng/misc.o eng/nls.o + eng/mouse.o eng/misc.o eng/nls.o eng/sort.o MAIN_OBJECTS = main/dllmain.o main/svctabm.o diff --git a/reactos/subsys/win32k/stubs/stubs.c b/reactos/subsys/win32k/stubs/stubs.c index fb34177b232..17d2d6f5c51 100644 --- a/reactos/subsys/win32k/stubs/stubs.c +++ b/reactos/subsys/win32k/stubs/stubs.c @@ -58,7 +58,6 @@ STUB(EngSetLastError) STUB(EngSetPointerShape) STUB(EngSetPointerTag) STUB(EngSetPrinterData) -STUB(EngSort) STUB(EngStretchBlt) STUB(EngStrokeAndFillPath) STUB(EngStrokePath) diff --git a/reactos/subsys/win32k/win32k.def b/reactos/subsys/win32k/win32k.def index ca25157c261..42abf863248 100644 --- a/reactos/subsys/win32k/win32k.def +++ b/reactos/subsys/win32k/win32k.def @@ -1,4 +1,4 @@ -; $Id: win32k.def,v 1.17 2003/06/21 18:06:11 ekohl Exp $ +; $Id: win32k.def,v 1.18 2003/07/12 12:45:29 gvg Exp $ ; ; win32k.def ; @@ -92,7 +92,7 @@ EngSetLastError EngSetPointerShape EngSetPointerTag EngSetPrinterData -EngSort +EngSort@16 EngStretchBlt EngStrokeAndFillPath EngStrokePath diff --git a/reactos/subsys/win32k/win32k.edf b/reactos/subsys/win32k/win32k.edf index b02aa035ccb..91628ccc386 100644 --- a/reactos/subsys/win32k/win32k.edf +++ b/reactos/subsys/win32k/win32k.edf @@ -1,4 +1,4 @@ -; $Id: win32k.edf,v 1.11 2003/06/21 18:06:11 ekohl Exp $ +; $Id: win32k.edf,v 1.12 2003/07/12 12:45:29 gvg Exp $ ; ; win32k.def ; @@ -92,7 +92,7 @@ EngSetLastError EngSetPointerShape EngSetPointerTag EngSetPrinterData -EngSort +EngSort=EngSort@16 EngStretchBlt EngStrokeAndFillPath EngStrokePath