www.pudn.com > WinGOS.rar > PowerManager.h


#ifndef _GOS_POWERMANAGER_H_ 
#define _GOS_POWERMANAGER_H_ 
 
enum _tagPowerManager 
{ 
	PS_FULL,	//设备全速;CPU全功率运行 
	PS_LOW,		//设备低速;CPU低速运行 
	PS_PAUSE,	//设备暂停;CPU停止,RAM在刷新 
	PS_SUSPEND,	//设备挂起;CPU停止,RAM低速刷新 
	PS_OFF,		//设备关闭;系统关闭 
 
	msgPmDetect=MAKEMSG(PriorityNormal,MsgClassPower,1), 
}; 
 
class CPowerManager : public CMsgObject 
{ 
public: 
	int DetectPS(); 
	int SetPowerState(); 
	int GetPowerStete(); 
	BOOL AddDevice(CDevice* pDevice) 
		{ m_aDevice.Add(pDevice); } 
	BOOL RemoveDevice(CDevice* pDevice); 
protected: 
	CArray  m_aDevice; 
}; 
 
#endif //_GOS_POWERMANAGER_H_