#ifndef _TESTSWITCH_H
#define _TESTSWITCH_H
static char TestSwitch_h_id[] = "$Header: /usr/tiburon/unix/gui/tmacs/RCS/TestSwitch.h,v 1.2 1997/05/07 18:08:26 oreilly Exp $";

/*
$Log: TestSwitch.h,v $
Revision 1.2  1997/05/07 18:08:26  oreilly
Delete contained DmInputDetector in destructor.

 * Revision 1.1  96/10/28  09:14:08  09:14:08  oreilly (Thomas C. O'Reilly)
 * Initial revision
 * 
*/

#include "DmGuiObject.h"
#include "DynamicButton.h"
#include "DmInputDetector.h"
#include "powerTypes.h"

#define SWITCH_REQUEST ".SWITCH_REQ"
#define SWITCH_STATUS ".SWITCH_STATUS"
#define SWITCH_CURRENT ".CURRENT"

class TestSwitch : public DmGuiObject
{
  public:

  TestSwitch(const char *name, Widget parent, const char *switchName,
	      int period);

  ~TestSwitch();

  virtual const char *className()
  {
    return "TestSwitch";
  }
  
  virtual void updateGui(DM_Item handle = 0);
  virtual void updateFromPeer(DmGuiObject *peer, void *clientData);

  protected:
  char *_switchName;
  DynamicButton *_button;
  DmEnumObject *_dmRequest;
  DmEnumObject *_dmStatus;
  DmInt16Object *_dmCurrent;
  DmInputDetector *_statusDetector;
  
  Nat32 _status;
  Int16 _current;
  

};


#endif
