home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / mfc / ole / tstcon / tstcon.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-03-27  |  2.8 KB  |  106 lines

  1. // TestContainer98.h : main header file for the TESTCONTAINER98 application
  2. //
  3.  
  4. #if !defined(AFX_TESTCONTAINER98_H__198184FF_B837_11D0_8DF1_00C04FB68D60__INCLUDED_)
  5. #define AFX_TESTCONTAINER98_H__198184FF_B837_11D0_8DF1_00C04FB68D60__INCLUDED_
  6.  
  7. #if _MSC_VER >= 1000
  8. #pragma once
  9. #endif // _MSC_VER >= 1000
  10.  
  11. #ifndef __AFXWIN_H__
  12.     #error include 'stdafx.h' before including this file for PCH
  13. #endif
  14.  
  15. #include "resource.h"       // main symbols
  16.  
  17. const int TCLOG_NULL = 0;
  18. const int TCLOG_OUTPUTWINDOW = 1;
  19. const int TCLOG_DEBUG = 2;
  20. const int TCLOG_FILE = 3;
  21.  
  22. class CTCOptions
  23. {
  24. public:
  25.    CTCOptions();
  26.  
  27. public:
  28.    BOOL m_tUserMode;
  29.    int m_iLogType;
  30.    CString m_strLogFileName;
  31.    CString m_strProgID;
  32.    BOOL m_tAllowWindowless;
  33.    BOOL m_tQuickActivation;
  34.    BOOL m_tTwoPassDrawing;
  35.    BOOL m_tUseIPointerInactive;
  36.    BOOL m_tHonorIgnoreActivateWhenVisible;
  37.    BOOL m_tIOleInPlaceSiteEx;
  38.    BOOL m_tIOleInPlaceSiteWindowless;
  39.    BOOL m_tIAdviseSinkEx;
  40.    BOOL m_tSBindHost;
  41. };
  42.  
  43. class CTCCommandLineInfo :
  44.    public CCommandLineInfo
  45. {
  46. public:
  47.    CTCCommandLineInfo( CTCOptions* pOptions );
  48.  
  49.    void ParseInterfaceFlag( LPCTSTR pszParam );
  50.    void ParseOptionFlag( LPCTSTR pszParam );
  51.    void ParseParam( LPCTSTR pszParam, BOOL tFlag, BOOL tLast );
  52.    void ParseServiceFlag( LPCTSTR pszParam );
  53.  
  54. protected:
  55.    CTCOptions* m_pOptions;
  56.    BOOL m_tExpectingLogFileName;
  57.    BOOL m_tExpectingProgID;
  58. };
  59.  
  60. /////////////////////////////////////////////////////////////////////////////
  61. // CTestContainer98App:
  62. // See TestContainer98.cpp for the implementation of this class
  63. //
  64.  
  65. class CTestContainer98App : public CWinApp
  66. {
  67. public:
  68.     CTestContainer98App();
  69.  
  70. // Overrides
  71.     // ClassWizard generated virtual function overrides
  72.     //{{AFX_VIRTUAL(CTestContainer98App)
  73.     public:
  74.     virtual BOOL InitInstance();
  75.     //}}AFX_VIRTUAL
  76.  
  77. // Implementation
  78.     COleTemplateServer m_server;
  79.         // Server object for document creation
  80.  
  81.    CTCOptions m_options;
  82.  
  83.    void LoadRegistrySettings();
  84.    void SaveRegistrySettings();
  85.  
  86.     //{{AFX_MSG(CTestContainer98App)
  87.     afx_msg void OnAppAbout();
  88.     afx_msg void OnOptionsTraceLevelNone();
  89.     afx_msg void OnOptionsTraceLevelNormal();
  90.     afx_msg void OnOptionsTraceLevelVerbose();
  91.     afx_msg void OnUpdateOptionsTraceLevelNone(CCmdUI* pCmdUI);
  92.     afx_msg void OnUpdateOptionsTraceLevelNormal(CCmdUI* pCmdUI);
  93.     afx_msg void OnUpdateOptionsTraceLevelVerbose(CCmdUI* pCmdUI);
  94.     afx_msg void OnFileRegisterControls();
  95.     //}}AFX_MSG
  96.     DECLARE_MESSAGE_MAP()
  97. };
  98.  
  99.  
  100. /////////////////////////////////////////////////////////////////////////////
  101.  
  102. //{{AFX_INSERT_LOCATION}}
  103. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  104.  
  105. #endif // !defined(AFX_TESTCONTAINER98_H__198184FF_B837_11D0_8DF1_00C04FB68D60__INCLUDED_)
  106.