www.pudn.com > VCShell_Samples.rar > MainFrm.h


/* 
modified by wenyy 1999/08/16 
1 enum all screen saver on os and add them to menu 
2 access the screen saver by menu 
 
*/ 
 
/******************************************************************************* 
* File : mainfrm.h 
******************************************************************************** 
* Program : ScreenSaverTrayIcon 
******************************************************************************** 
* Version : 1.0                       * Author : T.Maurel 
* Date    : 04/26/1999 
* 
* 
* 
* 
* 
* Main frame window definition 
*******************************************************************************/ 
#include "trayicon2.h" 
 
 
///////////////////////////////////////////////////////////////// 
// 
// 
class CMainFrame : public CFrameWnd { 
public: 
	CMainFrame(); 
	virtual ~CMainFrame(); 
protected: 
	DECLARE_DYNAMIC(CMainFrame) 
 
	void EnumAllSreenSaver(void); 
	void ListSS(LPCSTR pszDir); 
	CStringArray m_arrSS; 
	CMenu m_muPop; 
	CTrayIcon2	m_trayIcon;		// my tray icon 
 
// Internal use 
protected: 
	void ChangeIcon(BOOL bChange); 
 
public: 
// Overrides 
	// ClassWizard generated virtual function overrides 
	//{{AFX_VIRTUAL(CMainFrame) 
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs); 
	//}}AFX_VIRTUAL 
	 
protected: 
	//{{AFX_MSG(CMainFrame) 
	afx_msg LRESULT OnTrayNotification(WPARAM wp, LPARAM lp); 
	afx_msg int	 OnCreate(LPCREATESTRUCT lpCreateStruct); 
	afx_msg void OnAppStartSaver(); 
	afx_msg void OnTrayEnableScreensaver(); 
	afx_msg void OnAppDisplayProperties(); 
	afx_msg void OnTimer(UINT nIDEvent); 
	//}}AFX_MSG 
	afx_msg void OnQuickAcc( UINT nID ); 
	DECLARE_MESSAGE_MAP() 
};