home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / macfe / central / CTSMEditField.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  2.2 KB  |  79 lines

  1. /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  2.  *
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  *
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  *
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18.  
  19. #pragma once
  20.  
  21.  
  22. #include <TextEdit.h>
  23. #include <TextServices.h>
  24. #include <TSMTE.h>
  25. #include <LEditField.h>
  26.  
  27.  
  28. class CTSMEditField : public LEditField
  29.     {
  30.     
  31.         public:
  32.  
  33.             enum 
  34.                 {
  35.                     
  36.                     class_ID = 'Tedt'
  37.                     
  38.                 };
  39.                                 
  40.             CTSMEditField();                                        //    Ñ Default Constructor
  41.             CTSMEditField(    LStream        *inStream);                    //    Ñ Stream Constructor
  42.             CTSMEditField        (    const SPaneInfo&    inPaneInfo,
  43.                                         Str255            inString,
  44.                                         ResIDT            inTextTraitsID,
  45.                                         Int16            inMaxChars,
  46.                                         Uint8            inAttributes,
  47.                                         TEKeyFilterFunc    inKeyFilter,
  48.                                         LCommander*            inSuper);
  49.                                                                     //    Ñ Parameterized Constructor
  50.             virtual                        ~CTSMEditField();
  51.  
  52.             static pascal void     PreUpdate(            TEHandle     inTEHandle,
  53.                                                     Int32            inRefCon);
  54.             static pascal void    PostUpdate( 
  55.                                     TEHandle inTEHandle, 
  56.                                     Int32 fixLen, 
  57.                                     Int32 inputAreaStart, 
  58.                                     Int32 inputAreaEnd, 
  59.                                     Int32 pinStart, 
  60.                                     Int32 pinEnd, 
  61.                                     Int32 inRefCon );
  62.  
  63.         protected:
  64.  
  65.             virtual    void                BeTarget(void);
  66.             virtual void                DontBeTarget(void);
  67.  
  68.             virtual void                Initialize();
  69.             
  70.             TSMDocumentID                            mTSMDocID;
  71.             TSMTERecHandle                        mTSMTEHandle;
  72.             
  73.             static Boolean                        sInitialized;
  74.             static Boolean                        sHasTSM;
  75.             static TSMTEPreUpdateUPP    sPreUpdateUPP;
  76.             static TSMTEPostUpdateUPP    sPostUpdateUPP;
  77.             
  78.     };
  79.