home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
cset21v1.zip
/
IBMCPP
/
IBMCLASS
/
IPAGEEVT.HPP
< prev
next >
Wrap
C/C++ Source or Header
|
1993-10-22
|
12KB
|
227 lines
#ifndef _IPAGEEVT_
#define _IPAGEEVT_
/*******************************************************************************
* FILE NAME: ipageevt.hpp *
* *
* DESCRIPTION: *
* Declaration of the class(es): *
* IPageEvent - Notebook page notification event *
* IPageRemoveEvent - Notebook page deletion notification event *
* IPageHelpEvent - Notebook page help notification event *
* IPageSelectEvent - Notebook page selection notification event *
* *
* COPYRIGHT: *
* (C) Copyright IBM Corporation 1992 *
* All Rights Reserved *
* Licensed Materials = Property of IBM *
* *
*******************************************************************************/
#ifndef _ICTLEVT_
#include <ictlevt.hpp>
#endif
#ifndef _INOTEBK_
#include <inotebk.hpp>
#endif
/*----------------------------------------------------------------------------*/
/* Align classes on four byte boundary. */
/*----------------------------------------------------------------------------*/
#pragma pack(4)
// Forward declarations for other classes:
class IBitmapHandle;
class IHelpWindow;
class IPageHandle;
class IWindow;
class IPageEvent : public IControlEvent {
typedef IControlEvent
Inherited;
/*******************************************************************************
* The IPageEvent class represents a notification for a page-related notebook *
* event. An IPageEvent object is created by a notebook page handler when a *
* notebook page is resized. The IPageEvent class is also the base class for *
* other page-related events. *
* *
* Page events are first dispatched to the notebook, and then to the *
* owner window of the notebook. *
*******************************************************************************/
public:
/*------------------------------- Constructors ---------------------------------
| You can construct an instance of this class in the following ways: |
| - From an IEvent object |
| - From an IControlEvent object |
------------------------------------------------------------------------------*/
IPageEvent ( IEvent& event );
IPageEvent ( IControlEvent& controlEvent );
virtual
IPageEvent :: ~IPageEvent ( );
/*--------------------------- Control Information ------------------------------
| The following functions return information about the notebook and its page: |
| pageHandle - Returns the notebook page handle that is the subject of the |
| notification event. |
| notebook - Returns the notebook object to which the page belongs. |
------------------------------------------------------------------------------*/
virtual IPageHandle
pageHandle ( ) const;
virtual INotebook
*notebook ( ) const;
}; // IPageEvent
class IPageRemoveEvent : public IPageEvent {
typedef IPageEvent
Inherited;
/*******************************************************************************
* The IPageRemoveEvent class represents a notification for when a page is *
* deleted from a notebook. An IPageRemoveEvent object is created and used by *
* a notebook page handler. *
* *
* These events provide functions to return the application page window and *
* bit map. It is the application's responsibility to delete the window and *
* bit map, if any. *
* *
* These events are first dispatched to the notebook, then to the owner window *
* of the notebook. *
*******************************************************************************/
public:
/*------------------------------- Constructors ---------------------------------
| You can construct an instance of this class in the following ways: |
| - From an IEvent object |
| - From an IControlEvent object |
| - From an IPageEvent object |
------------------------------------------------------------------------------*/
IPageRemoveEvent ( IEvent& event );
IPageRemoveEvent ( IControlEvent& controlEvent );
IPageRemoveEvent ( IPageEvent& pageEvent );
virtual
IPageRemoveEvent :: ~IPageRemoveEvent ( );
/*----------------------------- Page Information -------------------------------
| These functions return information about the deleted page: |
| pageWindow - Returns the window or control associated with the page. |
| tabBitmap - Returns the handle of the bit map used by the tab associated |
| with the page. |
| notebook - Returns the notebook object to which the page belongs. |
------------------------------------------------------------------------------*/
IWindow
*pageWindow ( ) const;
IBitmapHandle
tabBitmap ( ) const;
virtual INotebook
*notebook ( ) const;
private:
/*--------------------------------- Private ----------------------------------*/
virtual IPageHandle
pageHandle ( ) const;
}; // IPageRemoveEvent
class IPageHelpEvent : public IPageEvent {
typedef IPageEvent
Inherited;
/*******************************************************************************
* The IPageHelpEvent class represents a notification that help has been *
* requested for a notebook page. An IPageHelpEvent object is created and *
* used by a notebook page handler. *
* *
* These events are first dispatched to the notebook, then to the owner window *
* of the notebook. *
*******************************************************************************/
public:
/*------------------------------- Constructors ---------------------------------
| You can construct an instance of this class in the following ways: |
| - From an IEvent object |
| - From an IControlEvent object |
| - From an IPageEvent object |
------------------------------------------------------------------------------*/
IPageHelpEvent ( IEvent& event );
IPageHelpEvent ( IControlEvent& controlEvent );
IPageHelpEvent ( IPageEvent& pageEvent );
virtual
IPageHelpEvent :: ~IPageHelpEvent ( );
/*----------------------------- Help Information -------------------------------
| This class returns the following help information: |
| helpWindow - Returns the help window that can be used to display help for |
| the notebook page. |
------------------------------------------------------------------------------*/
IHelpWindow
*helpWindow ( ) const;
/*-------------------------------- Overrides -----------------------------------
| This class overrides the following inherited functions: |
| pageHandle - Returns the handle of the notebook page for which help has |
| been requested. |
| notebook - Returns the notebook object to which the page belongs. |
------------------------------------------------------------------------------*/
virtual IPageHandle
pageHandle ( ) const;
virtual INotebook
*notebook ( ) const;
}; // IPageHelpEvent
class IPageSelectEvent : public IPageEvent {
typedef IPageEvent
Inherited;
/*******************************************************************************
* The IPageSelectEvent class represents a notification that a page has been *
* selected in a notebook. An IPageSelectEvent object is created and used by *
* a notebook page handler. *
* *
* These events are first dispatched to the notebook, then to the owner window *
* of the notebook. *
*******************************************************************************/
public:
/*------------------------------- Constructors ---------------------------------
| You can construct an instance of this class in the following ways: |
| - From an IEvent object |
| - From an IControlEvent object |
| - From an IPageEvent object. |
------------------------------------------------------------------------------*/
IPageSelectEvent ( IEvent& event );
IPageSelectEvent ( IControlEvent& controlEvent );
IPageSelectEvent ( IPageEvent& pageEvent );
virtual
IPageSelectEvent :: ~IPageSelectEvent ( );
/*-------------------------------- Overrides -----------------------------------
| This class overrides the following inherited functions: |
| pageHandle - Returns the handle of the selected notebook page. |
| notebook - Returns the notebook object to which the page belongs. |
------------------------------------------------------------------------------*/
virtual IPageHandle
pageHandle ( ) const;
virtual INotebook
*notebook ( ) const;
/*------------------- Previously Selected Page Information ---------------------
| The following function returns information about the previously selected |
| notebook page: |
| previousSelectedPageHandle - Returns the handle of the previously |
| selected notebook page. |
------------------------------------------------------------------------------*/
IPageHandle
previousSelectedPageHandle ( ) const;
}; // IPageSelectEvent
/*----------------------------------------------------------------------------*/
/* Resume compiler default packing. */
/*----------------------------------------------------------------------------*/
#pragma pack()
/*----------------------------- Inline Functions -----------------------------*/
#ifndef I_NO_INLINES
#include <ipageevt.inl>
#endif
#endif /* _IPAGEEVT_ */