home *** CD-ROM | disk | FTP | other *** search
/ IRIX 6.3 Development Libraries / SGI IRIX 6.3 Development Libraries.iso / dist6.3 / ViewKit_dev.idb / usr / share / src / ViewKit / Applications / PhoneBook / Entry.h.z / Entry.h
Encoding:
C/C++ Source or Header  |  1996-09-20  |  2.3 KB  |  60 lines

  1. ////////////////////////////////////////////////////////////////////////////////
  2. ///////   Copyright 1992, Silicon Graphics, Inc.  All Rights Reserved.   ///////
  3. //                                                                            //
  4. // This is UNPUBLISHED PROPRIETARY SOURCE CODE of Silicon Graphics, Inc.;     //
  5. // the contents of this file may not be disclosed to third parties, copied    //
  6. // or duplicated in any form, in whole or in part, without the prior written  //
  7. // permission of Silicon Graphics, Inc.                                       //
  8. //                                                                            //
  9. // RESTRICTED RIGHTS LEGEND:                                                  //
  10. // Use,duplication or disclosure by the Government is subject to restrictions //
  11. // as set forth in subdivision (c)(1)(ii) of the Rights in Technical Data     //
  12. // and Computer Software clause at DFARS 252.227-7013, and/or in similar or   //
  13. // successor clauses in the FAR, DOD or NASA FAR Supplement. Unpublished -    //
  14. // rights reserved under the Copyright Laws of the United States.             //
  15. //                                                                            //
  16. ////////////////////////////////////////////////////////////////////////////////
  17. #ifndef ENTRY_H
  18. #define ENTRY_H
  19.  
  20. #include <Vk/VkComponent.h>
  21. #include "Data.h"
  22.  
  23. class Entries;
  24. class EntryDialog;
  25.  
  26. class Entry : public VkComponent {
  27.   public:
  28.     Entry(const char *name, Widget parent, Entries *entries);
  29.     ~Entry();
  30.  
  31.     const char *className();
  32.  
  33.     void setInfo(DataElement *element);
  34.     char *getName() { return nameV; }
  35.     char *getPhone() { return phoneV; }
  36.     char *getAddr() { return addrV; }
  37.     char *getComment() { return commentV; }
  38.     void changeInfo(char *name, char *phone, char *addr, char *comment);
  39.  
  40.     DataElement *element() { return elementV; }
  41.     EntryDialog *entryDialog();
  42.     void clearDialog();
  43.  
  44.   protected:
  45.     void updateInfo(DataElement *element);
  46.     void setLabel(Widget label, char *value, int indent);
  47.     void menu(XEvent *event);
  48.     
  49.     static void buttonHandler(Widget w, XtPointer clientData, XEvent *event,
  50.                   Boolean *dispatch);
  51.  
  52.     Widget header, nameF, phoneF, addrF, commentF;
  53.     char *nameV, *phoneV, *addrV, *commentV;
  54.     DataElement *elementV;
  55.     Entries *entries;
  56.     EntryDialog *dialog;
  57. };
  58.  
  59. #endif
  60.