Annotation of sql/odbc/MFCpatches/stdafx.h, revision 1.1
1.1 ! paf 1: // STDAFX.H is the header that includes the standard includes that are used
! 2: // for most of the project. These are compiled into a pre-compiled header
! 3:
! 4: #define WINVER 0x0501 // Target Windows XP and Windows .NET Server
! 5:
! 6: // turn off warnings for /W4 (just for MFC implementation)
! 7: #ifndef ALL_WARNINGS
! 8: #pragma warning(disable: 4073) // disable warning about using init_seg
! 9: #pragma warning(disable: 4702) //REVIEW unreachable code
! 10: #endif
! 11:
! 12: // MFC inline constructors (including compiler generated) can get deep
! 13: #pragma inline_depth(16)
! 14:
! 15: #ifdef _AFX_DEVBUILD
! 16: #define AFX_IMPL_DATA AFX_DATA_EXPORT
! 17: #else
! 18: #define AFX_IMPL_DATA
! 19: #endif
! 20:
! 21: #ifdef _AFX_MFCS // Building the static component of the DLL version. Import stuff from MFC71.dll
! 22: #include <afxv_dll.h>
! 23: #else // Building the DLL itself
! 24: // override default values for data import/export when building MFC DLLs
! 25: #ifdef _AFX_CORE_IMPL
! 26: #define AFX_CORE_DATA AFX_IMPL_DATA
! 27: #define AFX_CORE_DATADEF
! 28: #endif
! 29:
! 30: #ifdef _AFX_OLE_IMPL
! 31: #define AFX_OLE_DATA AFX_IMPL_DATA
! 32: #define AFX_OLE_DATADEF
! 33: #endif
! 34:
! 35: #ifdef _AFX_DB_IMPL
! 36: #define AFX_DB_DATA AFX_IMPL_DATA
! 37: #define AFX_DB_DATADEF
! 38: #endif
! 39:
! 40: #ifdef _AFX_NET_IMPL
! 41: #define AFX_NET_DATA AFX_IMPL_DATA
! 42: #define AFX_NET_DATADEF
! 43: #endif
! 44: #endif
! 45:
! 46: #define _AFX_NOFORCE_LIBS
! 47: #define _AFX_FULLTYPEINFO
! 48: #define VC_EXTRALEAN
! 49: #define NO_ANSIUNI_ONLY
! 50: #define _MFC_OVERRIDES_NEW
! 51:
! 52: #define AFX_COMDAT __declspec(selectany)
! 53:
! 54: #ifdef _WIN64
! 55: #ifndef _AFX_NO_DAO_SUPPORT
! 56: #define _AFX_NO_DAO_SUPPORT
! 57: #endif
! 58: #endif
! 59:
! 60: // core headers
! 61: #include "afx.h"
! 62: #include "afxplex_.h"
! 63: #include "atlbase.h"
! 64: #include "afxcoll.h"
! 65: #include "afxtempl.h"
! 66:
! 67: // public headers
! 68: #include "afxwin.h"
! 69: #include "afxdlgs.h"
! 70: #include "afxext.h"
! 71:
! 72: #ifndef _AFX_NO_OLE_SUPPORT
! 73: #ifndef _OLE2_H_
! 74: #include <ole2.h>
! 75: #endif
! 76:
! 77: #include <winspool.h>
! 78:
! 79: // for the release version, MFC internally can use the more efficient
! 80: // method of directly accessing CRuntimeClass objects.
! 81: #ifndef _DEBUG
! 82: #undef RUNTIME_CLASS
! 83: #define RUNTIME_CLASS(class_name) _RUNTIME_CLASS(class_name)
! 84: #endif
! 85:
! 86: // include OLE dialog/helper APIs
! 87: #ifndef _OLEDLG_H_
! 88: #include <oledlg.h>
! 89: #endif
! 90:
! 91: #include <winreg.h>
! 92: #include "afxcom_.h"
! 93: #include "afxole.h"
! 94: #include "afxdtctl.h"
! 95: #include "afxocc.h"
! 96:
! 97: #include "afxdocob.h"
! 98:
! 99: #ifndef _AFX_NO_DAO_SUPPORT
! 100: #include "afxdao.h"
! 101: #endif
! 102:
! 103: #include "afxodlgs.h"
! 104: #endif
! 105:
! 106: #ifndef _AFX_NO_OCX_SUPPORT
! 107: #include "afxctl.h"
! 108: #endif
! 109: #ifndef _AFX_NO_DB_SUPPORT
! 110: #include "afxdb.h"
! 111: #endif
! 112: #ifndef _AFX_NO_SYNC_SUPPORT
! 113: #include "afxmt.h"
! 114: #endif
! 115: #ifndef _AFX_NO_INET_SUPPORT
! 116: #include "afxinet.h"
! 117: #endif
! 118:
! 119: // private headers as well
! 120: #include "afxpriv.h"
! 121: #include "afximpl.h"
! 122: #include "winhand_.h"
! 123: #ifndef _AFX_NO_OLE_SUPPORT
! 124: #include "oleimpl2.h"
! 125: #endif
! 126: #ifndef _AFX_NO_OCX_SUPPORT
! 127: #include "ctlimpl.h"
! 128: #endif
! 129: #ifndef _AFX_NO_DB_SUPPORT
! 130: #include "dbimpl.h"
! 131: #endif
! 132: #ifndef _AFX_NO_DAO_SUPPORT
! 133: #include "daoimpl.h"
! 134: #endif
! 135: #ifndef _AFX_NO_SOCKET_SUPPORT
! 136: #ifndef _WINSOCKAPI_
! 137: #include <winsock.h>
! 138: #endif
! 139: #include "sockimpl.h"
! 140: #include "afxsock.h"
! 141: #endif
! 142: #ifndef _AFX_NO_AFXCMN_SUPPORT
! 143: #include "afxcmn.h"
! 144: #include "afxcview.h"
! 145: #endif
! 146: #ifndef _AFX_NO_RICHEDIT_SUPPORT
! 147: #include "afxrich.h"
! 148: #endif
! 149: #include "afxhtml.h"
! 150: #ifndef _AFX_NO_DHTML_SUPPORT
! 151: #include "afxdhtml.h"
! 152: #endif
! 153:
! 154: #include <winreg.h>
! 155: #include <winnls.h>
! 156: #include <stddef.h>
! 157: #include <limits.h>
! 158: #include <malloc.h>
! 159: #include <new.h>
! 160: #include <eh.h> // for set_terminate
! 161:
! 162: #undef AfxWndProc
! 163:
! 164: // implementation uses _AFX_PACKING as well
! 165: #ifdef _AFX_PACKING
! 166: #ifndef ALL_WARNINGS
! 167: #pragma warning(disable: 4103)
! 168: #endif
! 169: #pragma pack(_AFX_PACKING)
! 170: #endif
! 171:
! 172: // special exception handling just for MFC library implementation
! 173:
! 174: // MFC does not rely on auto-delete semantics of the TRY..CATCH macros,
! 175: // therefore those macros are mapped to something closer to the native
! 176: // C++ exception handling mechanism when building MFC itself.
! 177:
! 178: #undef TRY
! 179: #define TRY { try {
! 180:
! 181: #undef CATCH
! 182: #define CATCH(class, e) } catch (class* e) \
! 183: { ASSERT(e->IsKindOf(RUNTIME_CLASS(class))); UNUSED(e);
! 184:
! 185: #undef AND_CATCH
! 186: #define AND_CATCH(class, e) } catch (class* e) \
! 187: { ASSERT(e->IsKindOf(RUNTIME_CLASS(class))); UNUSED(e);
! 188:
! 189: #undef CATCH_ALL
! 190: #define CATCH_ALL(e) } catch (CException* e) \
! 191: { { ASSERT(e->IsKindOf(RUNTIME_CLASS(CException))); UNUSED(e);
! 192:
! 193: #undef AND_CATCH_ALL
! 194: #define AND_CATCH_ALL(e) } catch (CException* e) \
! 195: { { ASSERT(e->IsKindOf(RUNTIME_CLASS(CException))); UNUSED(e);
! 196:
! 197: #undef END_TRY
! 198: #define END_TRY } catch (CException* e) \
! 199: { ASSERT(e->IsKindOf(RUNTIME_CLASS(CException))); e->Delete(); } }
! 200:
! 201: #undef THROW_LAST
! 202: #define THROW_LAST() throw
! 203:
! 204: // Because of the above definitions of TRY...CATCH it is necessary to
! 205: // explicitly delete exception objects at the catch site.
! 206:
! 207: #define DELETE_EXCEPTION(e) do { e->Delete(); } while (0)
! 208: #define NO_CPP_EXCEPTION(expr)
! 209:
! 210:
! 211: /////////////////////////////////////////////////////////////////////////////
E-mail: