home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-385-Vol-1of3.iso / g / gina15.zip / demos / AddressView.h < prev    next >
C/C++ Source or Header  |  1992-02-27  |  2KB  |  85 lines

  1. // This may look like C code, but it is really -*- C++ -*-
  2.  
  3. //   Module      : AddressView.h   Version 1.6
  4. //   LastSCCS    : 7/29/91  18:00:07
  5. //   LastEdit    : "Wed Mar  6 15:59:16 1991"
  6. //   Description : 
  7. //   Author      : 
  8. //   Copyright   : GMD Schloss Birlinghoven
  9.  
  10. #ifndef AddressView_h
  11. #define AddressView_h
  12.  
  13. #include <Gina/GnObject.h>
  14. #include <Gina/GnRowColumn.h>
  15. #include <Gina/GnText.h>
  16. #include <Gina/GnLabelG.h>
  17.  
  18. class Address;
  19.  
  20.  
  21. class AddressView : public GnRowColumn {
  22.   public:
  23.     // Create a view for an Address
  24.     AddressView(Address * = 0);
  25.     
  26.     // Display an Address in the view
  27.     void Show(Address *);
  28.     
  29.     // Created an object from the view's contents (copies this->address)
  30.     Address *Get();
  31.  
  32.     // Callbacks
  33.     void add_value_changed_callback(GnCallback *);
  34.  
  35.     // New Resources
  36.     void setR_editable(Boolean);
  37.     Boolean getR_editable()
  38.     { return editable; };
  39.  
  40.     // Refine GnWidget::set_values()
  41.     virtual void set_values();
  42.  
  43.   protected:
  44.     // Display this->address in the view (only if widgets are created)
  45.     void Update();
  46.  
  47.     void value_changed(caddr_t);
  48.     
  49.     virtual void before_create();
  50.     virtual void after_create();
  51.     
  52.     GnText        last_name;
  53.     GnLabelGadget last_name_text;
  54.     GnText        first_names;
  55.     GnLabelGadget first_names_text;
  56.     GnText        street;
  57.     GnLabelGadget street_text;
  58.     GnText        house_number;
  59.     GnLabelGadget house_number_text;
  60.     GnText        city_code;
  61.     GnLabelGadget city_code_text;
  62.     GnText        city;
  63.     GnLabelGadget city_text;
  64.     GnText        local_area;
  65.     GnLabelGadget local_area_text;
  66.     GnText        country_code;
  67.     GnLabelGadget country_code_text;
  68.     GnText        telephone;
  69.     GnLabelGadget telephone_text;
  70.     GnText        email;
  71.     GnLabelGadget email_text;
  72.     GnText        creation_date;
  73.     GnLabelGadget creation_date_label;
  74.     GnText        last_modified;
  75.     GnLabelGadget last_modified_label;
  76.  
  77.     Address   *address;
  78.     Boolean    modified;
  79.     GnCallback *value_changed_callback;
  80.     Boolean    call_callbacks;
  81.     Boolean    editable;
  82. };
  83.  
  84. #endif AddressView_h
  85.