source: trunk/src/user32/stats.cpp@ 7640

Last change on this file since 7640 was 7640, checked in by sandervl, 24 years ago

stats dump function renamed

File size: 1.4 KB
Line 
1#include <os2win.h>
2#include <stats.h>
3
4#ifdef DEBUG
5
6static DWORD nrwindowdcsallocated = 0;
7static DWORD nrcalls_GetDCEx = 0;
8static DWORD nrcalls_ReleaseDC = 0;
9
10//******************************************************************************
11//******************************************************************************
12void STATS_GetDCEx(HWND hwnd, HDC hdc, HRGN hrgn, ULONG flags)
13{
14 nrwindowdcsallocated++;
15 nrcalls_GetDCEx++;
16}
17//******************************************************************************
18//******************************************************************************
19void STATS_ReleaseDC(HWND hwnd, HDC hdc)
20{
21 nrwindowdcsallocated--;
22 nrcalls_ReleaseDC++;
23}
24//******************************************************************************
25//******************************************************************************
26void STATS_DumpStatsUSER32()
27{
28 dprintf(("************* USER32 STATISTICS BEGIN *****************"));
29 dprintf(("Total nr of GetDCEx calls %d", nrcalls_GetDCEx));
30 dprintf(("Total nr of ReleaseDC calls %d", nrcalls_ReleaseDC));
31 dprintf(("Leaked DCs: %d", nrwindowdcsallocated));
32 dprintf(("************* USER STATISTICS END *****************"));
33}
34//******************************************************************************
35//******************************************************************************
36
37
38#endif //DEBUG
Note: See TracBrowser for help on using the repository browser.