]> git.saurik.com Git - wxWidgets.git/blob - src/msw/dummy.cpp
MDI fixes
[wxWidgets.git] / src / msw / dummy.cpp
1 /*
2 * File: dummy.cc
3 * Purpose: See below
4 * Author: Julian Smart
5 * Created: 1993
6 * Updated:
7 * Copyright: (c) 1993, AIAI, University of Edinburgh
8 */
9
10 /* A dummy file to include wx.h. If precompiling wx.h, I
11 * always start by compiling this and producing the PCH file.
12 * Then subsequent source files use the PCH file.
13 *
14 * If precompiling wx.h for wxWindows and derived apps,
15 * link dummy.obj with your program (the MSC 7 linker complains otherwise).
16 *
17 * This is the only convenient way I found to use precompiled headers
18 * under MSC 7.
19 *
20 * This will produce a big PCH file.
21 */
22
23 #if defined(__BORLANDC__)
24 #if !(defined(__WIN32__) || defined(__NT__) || defined(__WIN32__))
25 #pragma hdrfile "c:\wx\src\msw\wx.pch"
26 #endif
27
28 #pragma hdrstart
29 #endif
30
31 #include "wx/wxprec.h"
32
33 #ifdef __BORLANDC__
34 #pragma hdrstop
35 #endif
36
37 #include <windows.h>
38
39 #include "wx/msw/msvcrt.h"
40
41 // Foils optimizations in Visual C++ (see also app.cpp). Without it,
42 // dummy.obj isn't linked and we get a linker error.
43 #if defined(__VISUALC__)
44 char wxDummyChar = 0;
45 #endif
46
47 // if wxWindows is in the DLL link our entry point with the application
48 // N.B. see include/wx/app.h, we're now putting this in IMPLEMENT_APP so we
49 // don't have to link our apps with dummy.obj.
50
51 #if 0 // defined(WXUSINGDLL)
52
53 // NT defines APIENTRY, 3.x not
54 #if !defined(APIENTRY)
55 #define APIENTRY FAR PASCAL
56 #endif
57
58 int
59 #ifdef __WATCOMC__
60 PASCAL
61 #else
62 APIENTRY
63 #endif
64 WinMain(HINSTANCE hInstance,
65 HINSTANCE hPrevInstance,
66 LPSTR m_lpCmdLine,
67 int nCmdShow )
68 {
69 #if !WXUSINGDLL
70 wxCrtSetDbgFlag(_CRTDBG_LEAK_CHECK_DF);
71 #endif
72
73 return wxEntry((WXHINSTANCE) hInstance, (WXHINSTANCE) hPrevInstance,
74 m_lpCmdLine, nCmdShow);
75 }
76 #endif
77
78