home *** CD-ROM | disk | FTP | other *** search
- #ifndef _ICNREHDR_
- #define _ICNREHDR_
- /*******************************************************************************
- * FILE NAME: icnrehdr.hpp *
- * *
- * DESCRIPTION: *
- * Declaration of the class(es): *
- * ICnrEditHandler *
- * *
- * COPYRIGHT: *
- * (C) Copyright IBM Corporation 1992 *
- * All Rights Reserved *
- * Licensed Materials * Property of IBM *
- * *
- * HISTORY: *
- * $Log: R:/ibmclass/icnr/vcs/icnrehdr.hpv $
- //
- // Rev 1.6 26 Oct 1992 00:37:42 BOBLOVE
- //External Beta Release
- //
- // Rev 1.5 25 Oct 1992 16:27:54 nunn
- //changed library name to ICLUI
- //
- // Rev 1.4 25 Oct 1992 11:17:28 BOBLOVE
- //External Beta Release
- * *
- *******************************************************************************/
-
- #ifndef _IHANDLER_
- #include <ihandler.hpp>
- #endif
-
- #ifndef _ICNREEVT_
- #include <icnreevt.hpp>
- #endif
-
- class IHandlerWindow;
-
- class ICnrEditHandler : public IHandler
- {
- /*******************************************************************************
- * This class handles direct editing of data in the container. *
- *******************************************************************************/
- public:
-
- /*------------------------ CONSTRUCTORS/DESTRUCTORS ----------------------------
- | There is only one way to construct instances of this class: |
- | 1. The default with no parameters. |
- ------------------------------------------------------------------------------*/
- ICnrEditHandler();
-
- /*------------------------ EVENT PROCESSING FUNCTIONS --------------------------
- | These functions must be supplied by a derived class in order to provide |
- | processing for an edit event. |
- | beginEdit - An edit window has been opened in the container. |
- | reallocString - Text has been modified in the container and storage needs |
- | to be reallocated. If the data is an IString, the |
- | reallocation is provided by the default behavior of this |
- | function otherwise reallocation must be provided in the |
- | subclass. |
- | endEdit - Editing has ended. This is received after the |
- | reallocString is dispatched. |
- ------------------------------------------------------------------------------*/
- virtual Boolean
- beginEdit(ICnrBeginEditEvent& evt),
- reallocateString(ICnrReallocStringEvent& evt),
- endEdit(ICnrEndEditEvent& evt),
- isDataIString();
-
- /*-------------------------------- ACCESSORS -----------------------------------
- | These functions provide means of getting and setting the accessible |
- | attributes of instances of this class: |
- | |
- | setMLEHandler - Store a handler to be added to the Multiline edit field |
- | when it gets created. |
- ------------------------------------------------------------------------------*/
- void
- setMLEHandler(IHandler* MLEHandler);
-
- protected:
- /*----------------------------- IMPLEMENTATION ---------------------------------
- | These functions are used to implement the class: |
- | dispatchHandlerEvent - This function is responsible for routing the edit |
- | events to the appropriate event functions. |
- ------------------------------------------------------------------------------*/
- virtual Boolean
- dispatchHandlerEvent(IEvent& evt);
-
-
- private:
- IHandler
- *_phdrMLE;
-
- };
-
- /* INLINES */
-
- inline Boolean ICnrEditHandler :: isDataIString()
- {return true; }
-
- #endif