home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / gpfcnt.zip / CONT1.HPP < prev    next >
Text File  |  1994-05-01  |  3KB  |  94 lines

  1. #ifndef ACLIENT
  2. #define ACLIENT
  3.  
  4. #include <iWindow.hpp>                   //IWindow 
  5. #include <icmdhdr.hpp>                   //Command handler 
  6. #include <ientryfd.hpp>                  //IEntryField
  7.  
  8.  
  9. //**************************************************************************
  10. // Class:   AClient                                                       
  11. //                                                                         
  12. // Purpose: Build a wrapper around the client window generated by Gpf 
  13. //             
  14. //                                                                         
  15. //**************************************************************************
  16. class AClient : public IWindow,
  17.                      public ICommandHandler,
  18.                      public ICnrHandler
  19. {
  20. public:
  21.   AClient (IWindowHandle hwndClient) ;
  22.   ~AClient();
  23.  
  24. public:
  25.  
  26. protected:
  27.   virtual Boolean command(ICommandEvent& cmdevt);     //Process the command events
  28.   void ObkectDetails();
  29. private:
  30.   void Push();
  31.   void ObjektDetails();
  32.   
  33.   IContainerControl *cnr1, *cnr2;
  34.   ICnrEditHandler   * cnrEdit;
  35.   IContainerColumn *colName, *colCode, *colNumber;
  36.  
  37. }; // AClient
  38.  
  39.  
  40.  
  41. //**************************************************************************
  42. // Class:   Objekt                                                     *
  43. //                                                                         *
  44. // Purpose: Describes a generic Container object that contains 
  45. //          an ULONG and a string
  46. //                                                                         *
  47. //**************************************************************************
  48. class Objekt : public IContainerObject
  49.  
  50. {
  51. //    friend class IContainerColumn;
  52.       friend class AClient;
  53.  
  54.   public:
  55.  
  56.     Objekt(const IString& Name, const IPointerHandle& Icon,  
  57.            const IString& Code,
  58.            const ULONG ulNumber, AClient *owner);
  59.  
  60.     IString Code() const {  return strCode; }
  61.     ULONG   Number() const {  return ulNumber; }
  62.     void    setCode (IString code) {strCode = code;}
  63.     void    setNumber (ULONG number) {ulNumber = number;}
  64.  
  65.   private:
  66.     IString       strCode; 
  67.     ULONG         ulNumber;
  68.     AClient       *owner;
  69. };
  70.  
  71.  
  72. //**************************************************************************
  73. // Class:   ADialog
  74. //                                                                         
  75. // Purpose: Build a wrapper around the dialog window generated by Gpf
  76. //             
  77. //              THIS WINDOW STILL NEEDS A COMMAND HANLER !!!!!!
  78. //**************************************************************************
  79. class ADialog : public IWindow
  80. {
  81. public:
  82.   ADialog (IWindowHandle hwndClient, Objekt *obj) ;
  83.   ~ADialog();
  84.  
  85. public:
  86. //    void PushOK();
  87.  
  88. private:
  89.   IEntryField *EFName, *EFCode, *EFNumber;
  90.   Objekt      *Obj;
  91.  
  92. }; // End ADialog
  93. #endif
  94.