From 87dbaa9a05e47f16de6c9326b2151249cf3172d8 Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Tue, 1 Dec 1998 13:00:05 +0000 Subject: [PATCH] Implemented GdiFreeResources (GDI.609). --- if1632/gdi.spec | 2 +- objects/gdiobj.c | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/if1632/gdi.spec b/if1632/gdi.spec index 2501310bfeb..aab000b8fec 100644 --- a/if1632/gdi.spec +++ b/if1632/gdi.spec @@ -378,7 +378,7 @@ file gdi.exe 606 pascal16 SetMagicColors(word long word) SetMagicColors16 607 pascal GetRegionData(word long ptr) GetRegionData16 608 stub ExtCreateRegion -609 stub GDIFreeResources +609 pascal16 GdiFreeResources(long) GdiFreeResources 610 stub GDISignalProc32 611 stub GetRandomRgn 612 pascal16 GetTextCharset(word) GetTextCharset16 diff --git a/objects/gdiobj.c b/objects/gdiobj.c index eba145a3ad4..6550c1b8ade 100644 --- a/objects/gdiobj.c +++ b/objects/gdiobj.c @@ -947,6 +947,15 @@ DWORD WINAPI GdiSeeGdiDo( WORD wReqType, WORD wParam1, WORD wParam2, } } +/*********************************************************************** + * GdiFreeResources (GDI.609) + */ +WORD WINAPI GdiFreeResources( DWORD reserve ) +{ + return (WORD)( (int)LOCAL_CountFree( GDI_HeapSel ) * 100 / + (int)LOCAL_HeapSize( GDI_HeapSel ) ); +} + /*********************************************************************** * MulDiv16 (GDI.128) */