- Very basic implementation of ExtEscape
authorFilip Navara <filip.navara@gmail.com>
Sun, 8 Feb 2004 16:16:24 +0000 (16:16 +0000)
committerFilip Navara <filip.navara@gmail.com>
Sun, 8 Feb 2004 16:16:24 +0000 (16:16 +0000)
svn path=/trunk/; revision=8092

reactos/lib/gdi32/misc/stubs.c
reactos/lib/gdi32/objects/dc.c
reactos/subsys/win32k/objects/print.c

index e89cfd4..d2a17d9 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: stubs.c,v 1.46 2004/01/24 08:23:12 ekohl Exp $
+/* $Id: stubs.c,v 1.47 2004/02/08 16:16:24 navaraf Exp $
  *
  * reactos/lib/gdi32/misc/stubs.c
  *
@@ -162,25 +162,6 @@ Escape(
 }
 
 
-/*
- * @unimplemented
- */
-int
-STDCALL
-ExtEscape(
-       HDC             a0,
-       int             a1,
-       int             a2,
-       LPCSTR          a3,
-       int             a4,
-       LPSTR           a5
-       )
-{
-       SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
-       return 0;
-}
-
-
 /*
  * @unimplemented
  */
index 233fe44..ca923b6 100644 (file)
@@ -907,3 +907,20 @@ RectVisible(
 {
        return NtGdiRectVisible(a0,(RECT *)a1);
 }
+
+/*
+ * @implemented
+ */
+int
+STDCALL
+ExtEscape(
+       HDC             a0,
+       int             a1,
+       int             a2,
+       LPCSTR          a3,
+       int             a4,
+       LPSTR           a5
+       )
+{
+       return NtGdiExtEscape(a0, a1, a2, a3, a4, a5);
+}
index bb0e767..e7d1d7f 100644 (file)
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
-/* $Id: print.c,v 1.11 2003/08/19 11:48:50 weiden Exp $ */
+/* $Id: print.c,v 1.12 2004/02/08 16:16:24 navaraf Exp $ */
+
 #undef WIN32_LEAN_AND_MEAN
 #include <windows.h>
 #include <ddk/ntddk.h>
 #include <win32k/print.h>
+#include <win32k/dc.h>
 
 #define NDEBUG
 #include <win32k/debug1.h>
@@ -57,16 +59,34 @@ NtGdiEscape(HDC  hDC,
   UNIMPLEMENTED;
 }
 
-INT
-STDCALL
-NtGdiExtEscape(HDC  hDC,
-                   INT  Escape,
-                   INT  InSize,
-                   LPCSTR  InData,
-                   INT  OutSize,
-                   LPSTR  OutData)
+INT STDCALL
+NtGdiExtEscape(
+   HDC hDC,
+   INT Escape,
+   INT InSize,
+   LPCSTR InData,
+   INT OutSize,
+   LPSTR OutData)
 {
-  UNIMPLEMENTED;
+   PDC pDC = DC_LockDc(hDC);
+   INT Result;
+
+   if (pDC == NULL)
+   {
+      return -1;
+   }
+
+   Result = pDC->DriverFunctions.Escape(
+      pDC->Surface,
+      Escape,
+      InSize,
+      (PVOID)InData,
+      OutSize,
+      (PVOID)OutData);
+
+   DC_UnlockDc(hDC);
+
+   return Result;
 }
 
 INT