source: branches/swt/src/gdiplus/dbglocal.cpp@ 22118

Last change on this file since 22118 was 22118, checked in by rousseau, 10 years ago

Added the stub sources for 'gdiplus' [gdiplus]

Stuff for the 'gdiplus' module was cloned from 'gdi32'.
For the implementation, the main source will be the Wine Git Repository.

We start at the initial wine-commit for 'gdiplus' and climb up the
wine-repo, integrating into Odin.

Commit: bed761c9e72febb3b2d681fd4e540e149af9e71a
Wine git-repo: git://source.winehq.org/git/wine.git

File size: 2.5 KB
Line 
1/* $Id: dbglocal.cpp,v 1.10 2004-01-11 11:42:08 sandervl Exp $ */
2
3/*
4 * debug logging functions for OS/2
5 *
6 *
7 * Copyright 2000 Sander van Leeuwen
8 * Project Odin Software License can be found in LICENSE.TXT
9 */
10#include <os2wrap.h>
11#include <stdlib.h>
12#include <stdio.h>
13#include <string.h>
14#include <ctype.h>
15#include "dbglocal.h"
16
17#ifdef DEBUG
18
19USHORT DbgEnabledGDIPLUS[DBG_MAXFILES] = {0};
20USHORT DbgEnabledLvl2GDIPLUS[DBG_MAXFILES] = {0};
21
22static const char *DbgFileNames[DBG_MAXFILES] =
23{
24"gdiplus",
25"opengl",
26"callback",
27"dibsect",
28"initterm",
29"resource",
30"oslibgdi",
31"font",
32"text",
33"palette",
34"line",
35"oslibgpi",
36"region",
37"metafile",
38"dibitmap",
39"blit",
40"rgbcvt",
41"objhandle",
42"transform",
43"printer",
44"icm",
45"trace",
46"fontres",
47"devcontext"
48};
49//******************************************************************************
50//******************************************************************************
51void ParseLogStatusGDIPLUS()
52{
53 char *envvar = getenv(DBG_ENVNAME);
54 char *envvar2= getenv(DBG_ENVNAME_LVL2);
55 char *dbgvar;
56 int i;
57
58 for(i=0;i<DBG_MAXFILES;i++) {
59 DbgEnabledGDIPLUS[i] = 1;
60 }
61
62 if(!envvar)
63 return;
64
65 dbgvar = strstr(envvar, "dll");
66 if(dbgvar) {
67 if(*(dbgvar-1) == '-') {
68 for(i=0;i<DBG_MAXFILES;i++) {
69 DbgEnabledGDIPLUS[i] = 0;
70 }
71 }
72 }
73 for(i=0;i<DBG_MAXFILES;i++) {
74 int len = strlen(DbgFileNames[i]);
75 dbgvar = strstr(envvar, DbgFileNames[i]);
76 if(dbgvar && !islower(dbgvar[len])) {
77 if(*(dbgvar-1) == '-') {
78 DbgEnabledGDIPLUS[i] = 0;
79 }
80 else
81 if(*(dbgvar-1) == '+') {
82 DbgEnabledGDIPLUS[i] = 1;
83 }
84 }
85 }
86 if(envvar2) {
87 dbgvar = strstr(envvar2, "dll");
88 if(dbgvar) {
89 if(*(dbgvar-1) == '+') {
90 for(i=0;i<DBG_MAXFILES;i++) {
91 DbgEnabledLvl2GDIPLUS[i] = 1;
92 }
93 }
94 }
95 for(i=0;i<DBG_MAXFILES;i++) {
96 int len = strlen(DbgFileNames[i]);
97 dbgvar = strstr(envvar2, DbgFileNames[i]);
98 if(dbgvar && !islower(dbgvar[len])) {
99 if(*(dbgvar-1) == '-') {
100 DbgEnabledLvl2GDIPLUS[i] = 0;
101 }
102 else
103 if(*(dbgvar-1) == '+') {
104 DbgEnabledLvl2GDIPLUS[i] = 1;
105 }
106 }
107 }
108 }
109}
110//******************************************************************************
111//******************************************************************************
112
113#endif
Note: See TracBrowser for help on using the repository browser.