home *** CD-ROM | disk | FTP | other *** search
/ The CDPD Public Domain Collection for CDTV 3 / CDPDIII.bin / pd / programming / c / intuitionpp / ipp / cwindow.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-04-06  |  1.8 KB  |  73 lines

  1. ///////////////////////////////////////////////////////////////////////////////
  2. ///////////////////////////////////////////////////////////////////////////////
  3. ///////////////////                                        ////////////////////
  4. ///////////////////           file : cwindow.h             ////////////////////
  5. ///////////////////                                        ////////////////////
  6. ///////////////////////////////////////////////////////////////////////////////
  7. ///////////////////////////////////////////////////////////////////////////////
  8. //
  9. //    Class CWindow :
  10. //
  11. //        - Simple window handling, remember size, position, ... 
  12. //        between open and close. You can pass a NewWindow, ExtNewWindow
  13. //        or NewWindow and TagList structure to its constructor.
  14.  
  15.  
  16. #ifndef __CWINDOW__
  17. #define __CWINDOW__
  18.  
  19. #include <intuition/intuition.h>
  20.  
  21.  
  22. class CWindow
  23. {
  24. protected:
  25.     friend class Waiter;
  26.     friend class CScreen;
  27.  
  28.     BOOL initlibs();
  29.     struct ExtNewWindow *newwind;
  30.     struct Window *wind;
  31.     CScreen *screen;
  32.  
  33.     virtual void update();
  34. public:
  35.     CWindow();
  36.     CWindow(struct NewWindow *newwindow);
  37.     CWindow(struct ExtNewWindow *extnewwindow);
  38.     CWindow(struct NewWindow *newwindow, struct TagItem *tags);
  39.     ~CWindow();
  40.  
  41.     virtual BOOL open();
  42.     BOOL isopen();
  43.     virtual void close();
  44.     void resize(int sizex, int sizey);
  45.     void setpos(int x, int y);
  46.     void move(int x, int y);
  47.     void tofront();
  48.     void toback();
  49.     void activate();
  50.  
  51.     void settitle(char *string);
  52.     BOOL setlimit(int xmin, int ymin, int xmax, int ymax);
  53.     ULONG setflags(ULONG flags);
  54.     void setpointer(UWORD *pointerdata, int heigth, int width, int x0, int y0);
  55.     void clearpointer();
  56.     void refreshframe();
  57.  
  58.     int leftedge();
  59.     int topedge();
  60.     int width();
  61.     int height();
  62.     int minwidth();
  63.     int minheight();
  64.     int maxwidth();
  65.     int maxheight();
  66.     unsigned long flags();
  67.     int mousex();
  68.     int mousey();
  69. };
  70.  
  71.  
  72. #endif //__CWINDOW__
  73.