// CodeGear C++Builder
// Copyright (c) 1995, 2016 by Embarcadero Technologies, Inc.
// All rights reserved

// (DO NOT EDIT: machine generated header) 'wclPowerEvents.pas' rev: 31.00 (Windows)

#ifndef WclpowereventsHPP
#define WclpowereventsHPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member 
#pragma pack(push,8)
#include <System.hpp>
#include <SysInit.hpp>
#include <wclMessaging.hpp>
#include <wclErrors.hpp>

//-- user supplied -----------------------------------------------------------

namespace Wclpowerevents
{
//-- forward type declarations -----------------------------------------------
class DELPHICLASS TwclPowerEventsMonitor;
//-- type declarations -------------------------------------------------------
enum DECLSPEC_DENUM TwclPowerState : unsigned int { psResumeAutomatic, psResume, psSuspend, psUnknown };

typedef void __fastcall (__closure *TwclPowerStateChangedEvent)(System::TObject* Sender, const TwclPowerState State);

class PASCALIMPLEMENTATION TwclPowerEventsMonitor : public System::TObject
{
	typedef System::TObject inherited;
	
private:
	Wclmessaging::TwclMessageReceiver* FReceiver;
	TwclPowerStateChangedEvent FOnPowerStateChanged;
	bool __fastcall GetActive(void);
	
protected:
	virtual void __fastcall MessageReceived(Wclmessaging::TwclMessage* const Message);
	virtual void __fastcall DoPowerStateChanged(const TwclPowerState State);
	
public:
	__fastcall virtual TwclPowerEventsMonitor(void);
	__fastcall virtual ~TwclPowerEventsMonitor(void);
	int __fastcall Close(void);
	int __fastcall Open(void);
	__property bool Active = {read=GetActive, nodefault};
	__property TwclPowerStateChangedEvent OnPowerStateChanged = {read=FOnPowerStateChanged, write=FOnPowerStateChanged};
};


//-- var, const, procedure ---------------------------------------------------
}	/* namespace Wclpowerevents */
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_WCLPOWEREVENTS)
using namespace Wclpowerevents;
#endif
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// WclpowereventsHPP
