Fix typo in license headers
[oweals/cde.git] / cde / programs / dtmail / include / DtMail / EncryptedTextFieldUiItem.hh
1 /* $TOG: EncryptedTextFieldUiItem.hh /main/1 1997/11/07 15:44:39 mgreess $ */
2 /*
3  *+SNOTICE
4  *
5  *      RESTRICTED CONFIDENTIAL INFORMATION:
6  *      
7  *      The information in this document is subject to special
8  *      restrictions in a confidential disclosure agreement bertween
9  *      HP, IBM, Sun, USL, SCO and Univel.  Do not distribute this
10  *      document outside HP, IBM, Sun, USL, SCO, or Univel wihtout
11  *      Sun's specific written approval.  This documment and all copies
12  *      and derivative works thereof must be returned or destroyed at
13  *      Sun's request.
14  *
15  *      Copyright 1993 Sun Microsystems, Inc.  All rights reserved.
16  *
17  *+ENOTICE
18  */
19
20 #ifndef _ENCRYPTEDTEXTFIELDUIITEM_HH
21 #define _ENCRYPTEDTEXTFIELDUIITEM_HH
22
23 #include <stdlib.h>
24 #include <X11/Intrinsic.h>
25
26 #include <DtMail/DtMailTypes.h>
27
28 // derived class for prop sheet glue items for textfield
29 ////////////////////////////////////////////////////////
30 class EncryptedTextFieldUiItem : public PropUiItem {
31   
32 public:
33   EncryptedTextFieldUiItem(
34                 Widget w,
35                 int source,
36                 char *search_key,
37                 PropUiCallback validator = NULL,
38                 void * validator_data = NULL);
39   virtual ~EncryptedTextFieldUiItem() {if (NULL!=_text) free(_text);};
40
41   void          writeAllowed(DtMailBoolean);
42   virtual void  writeFromUiToSource();
43   virtual void  writeFromSourceToUi();
44
45 private:
46   DtMailBoolean _loading;
47   int           _maxtextlen;
48   char          *_text;
49   DtMailBoolean _writeAllowed;
50
51   void          validateLength(int);
52   void          verify(XmTextVerifyPtr);
53   static void   verifyCB(Widget, XtPointer, XtPointer);
54 };
55
56 #endif