1 // ************************************************************************************** 2 // File: MainFrm.h 3 // By: Arthur David Leather 4 // Created: 12/02/98 5 // Copyright @1998 Massachusetts Institute of Technology - All rights reserved. 6 // Description: H file for MainFrm.cpp. Contains variables and functions 7 // for Leash 8 // 9 // History: 10 // 11 // MM/DD/YY Inits Description of Change 12 // 12/02/98 ADL Original 13 // ************************************************************************************** 14 15 16 #if !defined(AFX_MAINFRM_H__6F45AD95_561B_11D0_8FCF_00C04FC2A0C2__INCLUDED_) 17 #define AFX_MAINFRM_H__6F45AD95_561B_11D0_8FCF_00C04FC2A0C2__INCLUDED_ 18 19 #if _MSC_VER >= 1000 20 #pragma once 21 #endif // _MSC_VER >= 1000 22 23 #include "LeashFrame.h" 24 #include "LeashUIApplication.h" 25 26 class CMainFrame : public CLeashFrame 27 { 28 private: 29 int m_winRectLeft; 30 int m_winRectTop; 31 int m_winRectRight; 32 int m_winRectBottom; 33 BOOL m_bOwnerCreated; 34 CDialog m_MainFrameOwner; 35 IUIApplication *pApplication; 36 37 protected: // create from serialization only 38 // Ribbon bar for the application 39 CMFCRibbonBar m_wndRibbonBar; 40 // Our own custom application button we can keep hidden. 41 CMFCRibbonApplicationButton m_wndApplicationButton; 42 43 44 CMainFrame(); 45 DECLARE_DYNCREATE(CMainFrame) 46 47 // Attributes 48 public: 49 static int m_whatSide; 50 #ifndef NO_STATUS_BAR 51 static CMFCStatusBar m_wndStatusBar; 52 #endif 53 static CMFCToolBar m_wndToolBar; 54 static BOOL m_isMinimum; 55 static BOOL m_isBeingResized; 56 static CImageList m_imageList; 57 static CImageList m_disabledImageList; 58 59 // Operations 60 public: 61 // Overrides 62 // ClassWizard generated virtual function overrides 63 //{{AFX_VIRTUAL(CMainFrame) 64 public: 65 virtual BOOL PreCreateWindow(CREATESTRUCT& cs); 66 virtual void RecalcLayout(BOOL bNotify = TRUE); 67 virtual BOOL PreTranslateMessage(MSG* pMsg); 68 protected: 69 virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam); 70 //}}AFX_VIRTUAL 71 72 // Implementation 73 public: 74 virtual ~CMainFrame(); 75 #ifdef _DEBUG 76 virtual void AssertValid() const; 77 virtual void Dump(CDumpContext& dc) const; 78 #endif 79 BOOL ShowTaskBarButton(BOOL bVisible); 80 81 protected: // control bar embedded members 82 83 84 // Generated message map functions 85 protected: 86 //{{AFX_MSG(CMainFrame) 87 afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct); 88 afx_msg void OnResetWindowSize(); 89 afx_msg void OnSizing(UINT fwSide, LPRECT pRect); 90 afx_msg void OnGetMinMaxInfo(MINMAXINFO FAR* lpMMI); 91 afx_msg void OnRibbonResize(); 92 afx_msg void OnClose(void); 93 //afx_msg void OnContextHelp(); 94 //}}AFX_MSG 95 DECLARE_MESSAGE_MAP() 96 }; 97 98 ///////////////////////////////////////////////////////////////////////////// 99 100 //{{AFX_INSERT_LOCATION}} 101 // Microsoft Developer Studio will insert additional declarations immediately before the previous line. 102 103 #endif // !defined(AFX_MAINFRM_H__6F45AD95_561B_11D0_8FCF_00C04FC2A0C2__INCLUDED_) 104