// [!output IMPL_FILE] : implementation file // #include "stdafx.h" [!if PROJECT_NAME_HEADER] #include "[!output PROJECT_NAME].h" [!endif] #include "[!output HEADER_FILE]" [!if !MERGE_FILE] #ifdef _DEBUG #define new DEBUG_NEW #endif [!endif] [!if CCOLORDIALOG || CFONTDIALOG || CPAGESETUPDIALOG || CPRINTDIALOG] #ifndef _WIN32_WCE // [!output BASE_CLASS] is not supported for Windows CE. [!endif] // [!output CLASS_NAME] [!if CREATABLE] IMPLEMENT_DYNCREATE([!output CLASS_NAME], [!output BASE_CLASS]) [!else] IMPLEMENT_DYNAMIC([!output CLASS_NAME], [!output BASE_CLASS]) [!endif] [!if CCOLORDIALOG] [!output CLASS_NAME]::[!output CLASS_NAME](COLORREF clrInit, DWORD dwFlags, CWnd* pParentWnd) : CColorDialog(clrInit, dwFlags, pParentWnd) [!else] [!if CFILEDIALOG] [!output CLASS_NAME]::[!output CLASS_NAME](BOOL bOpenFileDialog, LPCTSTR lpszDefExt, LPCTSTR lpszFileName, DWORD dwFlags, LPCTSTR lpszFilter, CWnd* pParentWnd) : CFileDialog(bOpenFileDialog, lpszDefExt, lpszFileName, dwFlags, lpszFilter, pParentWnd) [!else] [!if CFONTDIALOG] [!output CLASS_NAME]::[!output CLASS_NAME](LPLOGFONT lplfInitial, DWORD dwFlags, CDC* pdcPrinter, CWnd* pParentWnd) : CFontDialog(lplfInitial, dwFlags, pdcPrinter, pParentWnd) [!else] [!if CPAGESETUPDIALOG] [!output CLASS_NAME]::[!output CLASS_NAME](DWORD dwFlags /*= PSD_MARGINS | PSD_INWININIINTLMEASURE*/, CWnd* pParentWnd /*= NULL*/) : CPageSetupDialog(dwFlags, pParentWnd) [!else] [!if CPRINTDIALOG] [!output CLASS_NAME]::[!output CLASS_NAME](BOOL bPrintSetupOnly, DWORD dwFlags, CWnd* pParentWnd) : CPrintDialog(bPrintSetupOnly, dwFlags, pParentWnd) [!else] [!output CLASS_NAME]::[!output CLASS_NAME]() [!endif] [!endif] [!endif] [!endif] [!endif] { [!if ACCESSIBILITY] #ifndef _WIN32_WCE EnableActiveAccessibility(); #endif [!endif] [!if AUTOMATION || CREATABLE] EnableAutomation(); [!endif] [!if CREATABLE] // To keep the application running as long as an OLE automation // object is active, the constructor calls AfxOleLockApp. AfxOleLockApp(); [!endif] } [!output CLASS_NAME]::~[!output CLASS_NAME]() { [!if CREATABLE] // To terminate the application when all objects created with // with OLE automation, the destructor calls AfxOleUnlockApp. AfxOleUnlockApp(); [!endif] } [!if AUTOMATION || CREATABLE] void [!output CLASS_NAME]::OnFinalRelease() { // When the last reference for an automation object is released // OnFinalRelease is called. The base class will automatically // deletes the object. Add additional cleanup required for your // object before calling the base class. [!output BASE_CLASS]::OnFinalRelease(); } [!endif] BEGIN_MESSAGE_MAP([!output CLASS_NAME], [!output BASE_CLASS]) END_MESSAGE_MAP() [!if AUTOMATION || CREATABLE] BEGIN_DISPATCH_MAP([!output CLASS_NAME], [!output BASE_CLASS]) END_DISPATCH_MAP() // Note: we add support for IID_I[!output CLASS_NAME_ROOT] to support typesafe binding // from VBA. This IID must match the GUID that is attached to the // dispinterface in the .IDL file. // {[!output DISPIID_REGISTRY_FORMAT]} static const IID IID_I[!output CLASS_NAME_ROOT] = [!output DISPIID_STATIC_CONST_GUID_FORMAT]; BEGIN_INTERFACE_MAP([!output CLASS_NAME], [!output BASE_CLASS]) INTERFACE_PART([!output CLASS_NAME], IID_I[!output CLASS_NAME_ROOT], Dispatch) END_INTERFACE_MAP() [!endif] [!if CREATABLE] // {[!output CLSID_REGISTRY_FORMAT]} IMPLEMENT_OLECREATE([!output CLASS_NAME], "[!output TYPEID]", [!output CLSID_IMPLEMENT_OLECREATE_FORMAT]) [!endif] // [!output CLASS_NAME] message handlers [!if CCONTROLBAR] void [!output CLASS_NAME]::OnUpdateCmdUI(CFrameWnd* /*pTarget*/, BOOL /*bDisableIfNoHndler*/) { } [!endif] [!if CCOLORDIALOG || CFONTDIALOG || CPAGESETUPDIALOG || CPRINTDIALOG] #endif // !_WIN32_WCE [!endif]