Subversion Repositories filter_foundry

Rev

Rev 407 | Rev 492 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 407 Rev 444
Line 33... Line 33...
33
        // Calling dynamically, because Windows NT 3.1 does not support CreateDIBSection
33
        // Calling dynamically, because Windows NT 3.1 does not support CreateDIBSection
34
        HMODULE hLib;
34
        HMODULE hLib;
35
        f_CreateDIBSection fCreateDIBSection;
35
        f_CreateDIBSection fCreateDIBSection;
36
        HBITMAP res;
36
        HBITMAP res;
37
 
37
 
38
        hLib = LoadLibraryA("GDI32.DLL");
38
        hLib = LoadLibrary(TEXT("GDI32.DLL"));
39
        if (!hLib) return 0;
39
        if (!hLib) return 0;
40
        fCreateDIBSection = (f_CreateDIBSection)(void*)GetProcAddress(hLib, "CreateDIBSection");
40
        fCreateDIBSection = (f_CreateDIBSection)(void*)GetProcAddress(hLib, "CreateDIBSection");
41
        if (fCreateDIBSection != 0) {
41
        if (fCreateDIBSection != 0) {
42
                res = fCreateDIBSection(hdc, pbmi, usage, ppvBits, hSection, offset);
42
                res = fCreateDIBSection(hdc, pbmi, usage, ppvBits, hSection, offset);
43
                FreeLibrary(hLib);
43
                FreeLibrary(hLib);
Line 84... Line 84...
84
                        for(i=pbmih->biWidth;i--;)
84
                        for(i=pbmih->biWidth;i--;)
85
                        p[i] = -( (i^j)&1 ) ;*/
85
                        p[i] = -( (i^j)&1 ) ;*/
86
 
86
 
87
                        return true;
87
                        return true;
88
                }else
88
                }else
89
                        dbg("CreateDIBSection FAILED");
89
                        dbg((TCHAR*)TEXT("CreateDIBSection FAILED"));
90
        }
90
        }
91
        return false;
91
        return false;
92
}
92
}
93
 
93
 
94
void disposebitmap(BITMAPREF pb){
94
void disposebitmap(BITMAPREF pb){
Line 113... Line 113...
113
        // Calling dynamically, because Windows 95 does not support GetMonitorInfoA
113
        // Calling dynamically, because Windows 95 does not support GetMonitorInfoA
114
        HMODULE hLib;
114
        HMODULE hLib;
115
        f_GetMonitorInfoA fGetMonitorInfoA;
115
        f_GetMonitorInfoA fGetMonitorInfoA;
116
        BOOL res;
116
        BOOL res;
117
 
117
 
118
        hLib = LoadLibraryA("USER32.DLL");
118
        hLib = LoadLibrary(TEXT("USER32.DLL"));
119
        if (!hLib) return 0;
119
        if (!hLib) return 0;
120
        fGetMonitorInfoA = (f_GetMonitorInfoA)(void*)GetProcAddress(hLib, "GetMonitorInfoA");
120
        fGetMonitorInfoA = (f_GetMonitorInfoA)(void*)GetProcAddress(hLib, "GetMonitorInfoA");
121
        if (fGetMonitorInfoA != 0) {
121
        if (fGetMonitorInfoA != 0) {
122
                res = fGetMonitorInfoA(hMonitor, lpmi);
122
                res = fGetMonitorInfoA(hMonitor, lpmi);
123
                FreeLibrary(hLib);
123
                FreeLibrary(hLib);
Line 133... Line 133...
133
        // Calling dynamically, because Windows 95 does not support MonitorFromRect
133
        // Calling dynamically, because Windows 95 does not support MonitorFromRect
134
        HMODULE hLib;
134
        HMODULE hLib;
135
        f_MonitorFromRect fMonitorFromRect;
135
        f_MonitorFromRect fMonitorFromRect;
136
        _HMONITOR res;
136
        _HMONITOR res;
137
 
137
 
138
        hLib = LoadLibraryA("USER32.DLL");
138
        hLib = LoadLibrary(TEXT("USER32.DLL"));
139
        if (!hLib) return 0;
139
        if (!hLib) return 0;
140
        fMonitorFromRect = (f_MonitorFromRect)(void*)GetProcAddress(hLib, "MonitorFromRect");
140
        fMonitorFromRect = (f_MonitorFromRect)(void*)GetProcAddress(hLib, "MonitorFromRect");
141
        if (fMonitorFromRect != 0) {
141
        if (fMonitorFromRect != 0) {
142
                res = fMonitorFromRect(lprc, dwFlags);
142
                res = fMonitorFromRect(lprc, dwFlags);
143
                FreeLibrary(hLib);
143
                FreeLibrary(hLib);