⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mainfrm.h

📁 我上载了那么多怎么都说已经有上载的啦
💻 H
字号:
// MainFrm.h : interface of the CMainFrame class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_MAINFRM_H__8088E124_A134_4C67_8D4B_6323A5901BEF__INCLUDED_)
#define AFX_MAINFRM_H__8088E124_A134_4C67_8D4B_6323A5901BEF__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "MultiViewSplitter.h"
///////////  for word //////////////////
#include "msword9.h"
///////////  for word //////////////////	

#include "global.h"
#include "PJNSMTP.h"

class CSelectView;
class CGPMISView;
class CSheetView;
class CThemeView;
class CTimeView;
class CScoreView;

class CMainFrame : public CFrameWnd
{
	
protected: // create from serialization only
	CMainFrame();
	DECLARE_DYNCREATE(CMainFrame)

// Attributes
public:

// Operations
public:
	static UINT SendMailThreadProc(LPVOID);
	static CPJNSMTPMessage* CreateMessage(const CMail& mail);
	static BOOL SendMail(const CMail& mail);

	void DrawTitle(CString strTitle = "");
	void SwitchRightViews(int nStyle);
	CView* GetCurrentView(int nStyle) const;

	void UpdateTime();
	void UpdateTask();
	void SetTask(const CString& strTask) {
		m_strTask = strTask;
	}

	CMultiViewSplitter* GetSplitter() {
		return &m_wndSplitter;
	}
	int GetCurrentViewID() const {
		return m_nCurrView;
	}
	int GetViewStyle() const {
		return m_nViewStyle;
	}
	void SetViewStyle(int nViewStyle)	{
		m_nViewStyle = nViewStyle;
	}
	int GetLevel() const {
		return m_nLevel;
	}
	void SetLevel(int nLevel)	{
		m_nLevel = nLevel;
	}
	CString GetFrmTitle() const {
		return m_strFrmTitle;
	}
	CSheetView* GetSheetView() {
		return m_pSheetView;
	}
	CThemeView* GetThemeView() {
		return m_pThemeView;
	}
	CTimeView* GetTimeView() {
		return m_pTimeView;
	}
	CScoreView* GetScoreView() {
		return m_pScoreView;
	}

	int GetYear() const {
		return m_nYear;
	} 
	void SetYear(int nYear) {
		m_nYear = nYear;
		CGlobal::GetInstance().CreateStudentList(m_nYear);
		CGlobal::GetInstance().CreateTeacherList(m_nYear);
	}

	void SetModifySheet( BOOL bModifySheet) {
		m_bModifySheet = bModifySheet;
	}
	void SetModifyTheme( BOOL bModifyTheme) {
		m_bModifyTheme = bModifyTheme;
	}
	void SetModifyScore( BOOL bModifyScore) {
		m_bModifyScore = bModifyScore;
	}

	void Mail2Admin();

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CMainFrame)
	public:
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual BOOL OnCreateClient(LPCREATESTRUCT lpcs, CCreateContext* pContext);
	//}}AFX_VIRTUAL

// Implementation
public:
	virtual ~CMainFrame();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:  // control bar embedded members
	CStatusBar  m_wndStatusBar;
	CToolBar    m_wndToolBar;

	CString m_strTask;

	CMultiViewSplitter m_wndSplitter;
	int m_nViewNo[5];
	int m_nCurrView;

	CSelectView* m_pSelectView;
	CSheetView* m_pSheetView;
	CThemeView* m_pThemeView;
	CTimeView* m_pTimeView;
	CScoreView* m_pScoreView;

	int m_nViewStyle;

	BOOL m_bCanSizing;

	int m_nLevel;

	CString m_strFrmTitle;

	int m_nYear;

	BOOL m_bModifySheet;
	BOOL m_bModifyTheme;
	BOOL m_bModifyScore;

	static BOOL m_bClosing;
	static CString m_sServer, m_sAddress, m_sUsername, m_sPassword;
	CString m_sEMail; // 管理员邮箱
	CMail m_mail;

// Generated message map functions
protected:
	//{{AFX_MSG(CMainFrame)
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnTeacherInfo();
	afx_msg void OnUpdateTeacherInfo(CCmdUI* pCmdUI);
	afx_msg void OnAdminPassword();
	afx_msg void OnUpdateAdminPassword(CCmdUI* pCmdUI);
	afx_msg void OnSetTerm();
	afx_msg void OnUpdateSetTerm(CCmdUI* pCmdUI);
	afx_msg void OnClose();
	afx_msg void OnDestroy();
	afx_msg void OnBackupDb();
	afx_msg void OnUpdateBackupDb(CCmdUI* pCmdUI);
	afx_msg void OnRestoreDb();
	afx_msg void OnUpdateRestoreDb(CCmdUI* pCmdUI);
	//}}AFX_MSG
	afx_msg void OnUpdateTime(CCmdUI* pCmdUI);
	afx_msg void OnUpdateTask(CCmdUI* pCmdUI);
	DECLARE_MESSAGE_MAP()
};

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_MAINFRM_H__8088E124_A134_4C67_8D4B_6323A5901BEF__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -