home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / treecnr.zip / TreeCnr.hpp < prev    next >
C/C++ Source or Header  |  1996-03-13  |  9KB  |  242 lines

  1. /*******************************************************************************
  2. * FILE NAME: TreeCnr.hpp                                                       *
  3. *                                                                              *
  4. * DESCRIPTION:                                                                 *
  5. *   Declaration of the class:                                                  *
  6. *     TreeCnr- Sample tree view container application                          *
  7. * ---------------------------------------------------------------------------- *
  8. * Warning: This file was generated by the VisualAge C++ Visual Builder.        *
  9. * Modifications to this source file will be lost when the part is regenerated. *
  10. *******************************************************************************/
  11. #ifndef _TREECNR_
  12. #define _TREECNR_  
  13.  
  14. class TreeCnr;
  15.  
  16. #ifndef _IFRAME_
  17. #include <iframe.hpp>
  18. #endif
  19.  
  20. class IMultiCellCanvas;
  21. #define INCL_WINSTDCNR
  22. #include <os2.h>
  23.  
  24. #ifndef _PERSON_
  25. #include "Person.hpp"
  26. #endif
  27.  
  28. #ifndef _IVSEQ_H_
  29. #include <ivseq.h>
  30. #endif
  31.  
  32. #ifndef _IVBCNR_
  33. #include <ivbcnr.h>
  34. #endif
  35.  
  36. class IContainerColumn;
  37. class IToolBar;
  38. class IToolBarButton;
  39. class IEntryField;
  40. class IInfoArea;
  41. template <class Element> class IVSequence;
  42. class Person;
  43. #ifndef _ISTDNTFY_
  44. #include <istdntfy.hpp>
  45. #endif
  46.  
  47. #ifndef _IVBVPRTP_
  48. #include <ivbvprtp.h>
  49. #endif
  50.  
  51. class IMessageBox;
  52. #ifndef _IRECT_
  53. #include <irect.hpp>
  54. #endif
  55.  
  56. #ifndef _ISTRING_
  57. #include <istring.hpp>
  58. #endif
  59.  
  60. #include "icnrolst.hpp"
  61.  
  62. class TreeCnrConn7;
  63. class TreeCnrConn9;
  64. class TreeCnrConn18;
  65. class TreeCnrConn29;
  66. class TreeCnrConn14;
  67. class TreeCnrConn15;
  68. class TreeCnrConn22;
  69. class TreeCnrConn12;
  70. class TreeCnrConn17;
  71. class TreeCnrConn44;
  72. class TreeCnrConn25;
  73. #include "TreeCnr.h"
  74.  
  75.  
  76. /*----------------------------------------------------------------------------*/
  77. /* Align classes on four byte boundary.                                       */
  78. /*----------------------------------------------------------------------------*/
  79. #pragma pack(4)
  80.  
  81. //*****************************************************************************
  82. // Class definition for TreeCnrTreeCnrCnrObj
  83. //*****************************************************************************
  84. class TreeCnrTreeCnrCnrObj : public IVBContainerObject {
  85. public:
  86.    //---------------------------------------------------------------------------
  87.    // Constructors / destructors
  88.    //---------------------------------------------------------------------------
  89.    TreeCnrTreeCnrCnrObj(Person& anObject);
  90.    TreeCnrTreeCnrCnrObj(TreeCnrTreeCnrCnrObj& anObject);
  91.  
  92.    virtual  ~TreeCnrTreeCnrCnrObj();
  93.  
  94.    //---------------------------------------------------------------------------
  95.    // public member functions
  96.    //---------------------------------------------------------------------------
  97.    IVBContainerObject & refreshFromObject();
  98.    IVBContainerObject & updateToObject();
  99.    TreeCnrTreeCnrCnrObj& operator=(const TreeCnrTreeCnrCnrObj& anObject);
  100.    Person* realObject() { return &pRealObject; }
  101. ;
  102.  
  103.    //---------------------------------------------------------------------------
  104.    // public member data
  105.    //---------------------------------------------------------------------------
  106.    IString phoneNumber;
  107.    IString parentName;
  108.  
  109. protected:
  110. private:
  111.    //---------------------------------------------------------------------------
  112.    // private member data
  113.    //---------------------------------------------------------------------------
  114.    Person & pRealObject;
  115.  
  116.  
  117. };   //TreeCnrTreeCnrCnrObj
  118.  
  119.  
  120. //*****************************************************************************
  121. // Class definition for TreeCnrPersonFactFactory
  122. //*****************************************************************************
  123. class TreeCnrPersonFactFactory : public IStandardNotifier {
  124. public:
  125.    //---------------------------------------------------------------------------
  126.    // Constructors / destructors
  127.    //---------------------------------------------------------------------------
  128.    TreeCnrPersonFactFactory();
  129.  
  130.    virtual  ~TreeCnrPersonFactFactory();
  131.  
  132.    //---------------------------------------------------------------------------
  133.    // public member functions
  134.    //---------------------------------------------------------------------------
  135.    Person * create();
  136.    TreeCnrPersonFactFactory & setAddEf(IEntryField * aSelf) {iAddEf = aSelf; return *this;};
  137.    TreeCnrPersonFactFactory & setSelPerson(IVBVariablePartPointer<Person *> * aSelf) {iSelPerson = aSelf; return *this;};
  138.  
  139.    //---------------------------------------------------------------------------
  140.    // public member data
  141.    //---------------------------------------------------------------------------
  142.    static const INotificationId newObjectCreatedId;
  143.  
  144. protected:
  145. private:
  146.    //---------------------------------------------------------------------------
  147.    // private member data
  148.    //---------------------------------------------------------------------------
  149.    IEntryField * iAddEf;
  150.    IVBVariablePartPointer<Person *> * iSelPerson;
  151.  
  152.  
  153. };   //TreeCnrPersonFactFactory
  154.  
  155.  
  156. //*****************************************************************************
  157. // Class definition for TreeCnr
  158. //*****************************************************************************
  159. class TreeCnr : public IFrameWindow {
  160. public:
  161.    //---------------------------------------------------------------------------
  162.    // Constructors / destructors
  163.    //---------------------------------------------------------------------------
  164.    TreeCnr(
  165.       unsigned long id = WND_TreeCnr,
  166.       IWindow* parent = IWindow::desktopWindow(),
  167.       IWindow* owner = 0,
  168.       const IRectangle& rect = defaultFramingSpec(),
  169.       const IFrameWindow::Style& style = IFrameWindow::defaultStyle ( ),
  170.       const char* title = defaultTitle());
  171.  
  172.    virtual  ~TreeCnr();
  173.  
  174.    //---------------------------------------------------------------------------
  175.    // public member functions
  176.    //---------------------------------------------------------------------------
  177.    static const IRectangle defaultFramingSpec();
  178.    static IString defaultTitle();
  179.    virtual TreeCnr & initializePart();
  180.    TreeCnr * getFrameWindow() { return this; };
  181.  
  182.    //---------------------------------------------------------------------------
  183.    // public member data
  184.    //---------------------------------------------------------------------------
  185.    static const INotificationId readyId;
  186.  
  187. protected:
  188.    //---------------------------------------------------------------------------
  189.    // protected member functions
  190.    //---------------------------------------------------------------------------
  191.    Boolean makeConnections();
  192.  
  193. private:
  194.    //---------------------------------------------------------------------------
  195.    // private member data
  196.    //---------------------------------------------------------------------------
  197.    IMultiCellCanvas * iMultiCellCanvas1;
  198.    IVBContainerControl< Person*, IVSequence<Person*>, TreeCnrTreeCnrCnrObj > * iTreeCnr;
  199.    IContainerColumn * iContainerColumn1;
  200.    IContainerColumn * iContainerColumn2;
  201.    IContainerColumn * iContainerColumn3;
  202.    IToolBar * iToolBar1;
  203.    IToolBarButton * iToolBarButton;
  204.    IEntryField * iAddEf;
  205.    IToolBarButton * iToolBarButton4;
  206.    IToolBarButton * iToolBarButton3;
  207.    IToolBarButton * iToolBarButton1;
  208.    IToolBarButton * iToolBarButton2;
  209.    IToolBarButton * iToolBarButton5;
  210.    IInfoArea * iInfoArea1;
  211.    IVSequence< Person * > * iPeople;
  212.    TreeCnrPersonFactFactory * iPersonFact;
  213.    IVBVariablePartPointer<Person *> * iSelPerson;
  214.    IMessageBox * iMessageBox;
  215.    TreeCnrConn7 * conn7;
  216.    TreeCnrConn9 * conn9;
  217.    TreeCnrConn18 * conn18;
  218.    TreeCnrConn29 * conn29;
  219.    TreeCnrConn14 * conn14;
  220.    TreeCnrConn15 * conn15;
  221.    TreeCnrConn22 * conn22;
  222.    TreeCnrConn12 * conn12;
  223.    TreeCnrConn17 * conn17;
  224.    TreeCnrConn44 * conn44;
  225.    TreeCnrConn25 * conn25;
  226.  
  227. friend class TreeCnrConn18;
  228. friend class TreeCnrConn15;
  229. friend class TreeCnrConn12;
  230. friend class TreeCnrConn17;
  231.  
  232. #include "treecnr.hpv"
  233. };   //TreeCnr
  234.  
  235.  
  236. /*----------------------------------------------------------------------------*/
  237. /* Resume compiler default packing.                                           */
  238. /*----------------------------------------------------------------------------*/
  239. #pragma pack()
  240.  
  241. #endif
  242.