home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / ool_main.zip / ool / include / xtraffic.h < prev    next >
C/C++ Source or Header  |  1998-01-18  |  1KB  |  42 lines

  1. #ifndef __OOL_XTRAFIC_H__
  2. #define __OOL_XTRAFIC_H__
  3.  
  4. /*===========================================================================*/
  5. /* OOL ------------------- the Open Object Library ------------------- r 1.0 */
  6. /*===========================================================================*/
  7. /*                              class: XTraficLight                          */
  8. /*                       derived from: XUserWindow                           */
  9. /*                        last update: 7/97                                  */
  10. /*                      programmed by: Stefan von Brauk (sbrauk@gwdg.de)     */
  11. /*===========================================================================*/
  12.  
  13.  
  14. #include "XfrmWnd.h"
  15. #include "xuserwnd.h"
  16. #include "xtext.h"
  17.  
  18. class XBitmap;
  19. class XGraphicDevice;
  20.  
  21. #define TRAFFIC_OFF         0
  22. #define TRAFFIC_GREEN         1
  23. #define TRAFFIC_YELLOW      2
  24. #define TRAFFIC_RED         3
  25. #define TRAFFIC_YELLOWRED   4
  26.  
  27. class _export_ XTrafficLight: public XUserWindow
  28. {
  29.    private:
  30.       SHORT state;
  31.       XGraphicDevice * dev;
  32.       XBitmap * map;
  33.    public:
  34.       virtual void Draw( void );
  35.       XTrafficLight( const XWindow *, const XPoint& = XPoint(), const USHORT id = 0);
  36.       ~XTrafficLight();
  37.       void SetState( const SHORT );
  38.       SHORT GetState() { return state; }
  39. };
  40.  
  41. #endif
  42.