home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
cset21v1.zip
/
IBMCPP
/
IBMCLASS
/
IHELPEVT.HPP
< prev
next >
Wrap
C/C++ Source or Header
|
1993-10-22
|
12KB
|
219 lines
#ifndef _IHELPEVT_
#define _IHELPEVT_
/*******************************************************************************
* FILE NAME: ihelpevt.hpp *
* *
* DESCRIPTION: *
* This file contains the declaration(s) of the class(es): *
* IHelpMenuBarEvent *
* IHelpErrorEvent *
* IHelpHypertextEvent *
* IHelpSubitemNotFoundEvent *
* IHelpTutorialEvent *
* IHelpNotifyEvent *
* *
* COPYRIGHT: *
* Licensed Materials - Property of IBM *
* (C) Copyright IBM Corporation 1992, 1993 *
* All Rights Reserved *
* US Government Users Restricted Rights - Use, duplication, or *
* disclosure *
* restricted by GSA ADP Schedule Contract with IBM Corp. *
* *
*******************************************************************************/
#ifndef _IEVENT_
#include <ievent.hpp>
#endif
/*----------------------------------------------------------------------------*/
/* Align classes on four byte boundary. */
/*----------------------------------------------------------------------------*/
#pragma pack(4)
// Forward declarations for other classes:
class IEvent;
class IHelpMenuBarEvent : public IEvent
{
typedef IEvent Inherited;
/*******************************************************************************
* The IHelpMenuBarEvent class is dispatched when the user has selected a *
* tailored menu bar item. *
*******************************************************************************/
public:
/*------------------------ Constructor -----------------------------------------
| The only way to construct an instance of this class is from an IEvent class. |
------------------------------------------------------------------------------*/
IHelpMenuBarEvent (IEvent& event);
~IHelpMenuBarEvent ();
/*-------------------------------- Accessors -----------------------------------
| This function provides a means of getting and setting the accessible |
| attributes of instances of this class: |
| |
| commandId - Returns the ID of the menu bar item selected. |
------------------------------------------------------------------------------*/
unsigned long
commandId() const;
};
class IHelpErrorEvent : public IEvent
{
typedef IEvent Inherited;
/*******************************************************************************
* The IHelpErrorEvent class is dispatched when a help error is caused by user *
* interaction. *
*******************************************************************************/
public:
/*------------------------ Constructor -----------------------------------------
| The only way to construct an instance of this class is from an IEvent class. |
------------------------------------------------------------------------------*/
IHelpErrorEvent (IEvent& event);
~IHelpErrorEvent ();
enum ErrorType
{ loadingDLL, noWindow, invalidAppHandle, invalidInstanceHandle,
noHelpInstance, invalidQueryHandle, noHelpTable,
invalidId, noIndex, noContent, openHelpFile,
readHelpFile, closeHelpFile, invalidHelpFile, notEnoughMemory,
unableFreeMemory, invalidHelpWindow, unopenDatabase, unknown };
/*-------------------------------- Accessor ------------------------------------
| This function provides a means of getting and setting the accessible |
| attributes of instances of this class: |
| |
| error - Returns the ErrorType caused by user interaction. |
------------------------------------------------------------------------------*/
IHelpErrorEvent::ErrorType
error() const;
};
class IHelpHypertextEvent : public IEvent
{
typedef IEvent Inherited;
/*******************************************************************************
* The IHelpHypertextEvent class is dispatched when the user selects a *
* hypertext field that was specified with the reftype=inform attribute of the *
* IPF :link tag. *
*******************************************************************************/
public:
/*------------------------ Constructor -----------------------------------------
| The only way to construct an instance of this class is from an IEvent class. | |
------------------------------------------------------------------------------*/
IHelpHypertextEvent (IEvent& event);
~IHelpHypertextEvent ();
/*-------------------------------- Accessor ------------------------------------
| This function provides a means of getting and setting the accessible |
| attributes of instances of this class: |
| |
| id - Returns the ID of the hypertext field. |
------------------------------------------------------------------------------*/
unsigned long
id() const;
};
class IHelpSubitemNotFoundEvent : public IEvent
{
typedef IEvent Inherited;
/*******************************************************************************
* The IHelpSubitemNotFoundEvent class is dispatched when the user has *
* requested help on a field for which IPF cannot find a related entry in the *
* help subtable. *
*******************************************************************************/
public:
/*------------------------ Constructor -----------------------------------------
| The only way to construct an instance of this class is from an IEvent class. |
------------------------------------------------------------------------------*/
IHelpSubitemNotFoundEvent (IEvent& event);
~IHelpSubitemNotFoundEvent ();
/*-------------------------------- Accessors -----------------------------------
| These functions provide means of getting and setting the accessible |
| attributes of instances of this class: |
| |
| isWindow - Queries whether help was requested on an application window. |
| isFrame - Queries whether help was requested on a frame window. |
| isMenu - Queries whether help was requested on a menu window. |
| topicId - Returns the ID of the window or menu that contains the |
| field upon which help was requested. |
| subtopicId - If help was requested on an application window, the control |
| ID of the cursored field is returned. If help was |
| requested from a menu window, the menu ID of the currently |
| selected submenu item is returned. |
------------------------------------------------------------------------------*/
Boolean
isWindow ( ) const,
isFrame ( ) const,
isMenu ( ) const;
unsigned long
topicId ( ) const,
subtopicId ( ) const;
};
class IHelpTutorialEvent : public IEvent
{
typedef IEvent Inherited;
/*******************************************************************************
* The IHelpTutorialEvent class is dispatched when the user selects the *
* Tutorial choice from the Help menu. *
*******************************************************************************/
public:
/*------------------------ Constructor -----------------------------------------
| The only way to construct an instance of this class is from an IEvent class. |
------------------------------------------------------------------------------*/
IHelpTutorialEvent ( IEvent& event);
~IHelpTutorialEvent ( );
/*-------------------------------- Accessor ------------------------------------
| This function provides a means of getting and setting the accessible |
| attributes of instances of this class: |
| |
| tutorialName - Returns the default tutorial program name specified upon |
| creating the IHelpWindow. |
------------------------------------------------------------------------------*/
IString
tutorialName ( ) const;
};
class IHelpNotifyEvent : public IEvent {
typedef IEvent Inherited;
/*******************************************************************************
* The IHelpNotifyEvent class is dispatched when the user initiates an event *
* that the owner might be interested in controlling. *
*******************************************************************************/
public:
/*------------------------ Constructor -----------------------------------------
| The only way to construct an instance of this class is from an IEvent class. |
------------------------------------------------------------------------------*/
IHelpNotifyEvent ( IEvent& event);
~IHelpNotifyEvent ( );
/*-------------------------------- Accessors -----------------------------------
| These functions provide means of getting and setting the accessible |
| attributes of instances of this class: |
| |
| windowHandle - Returns the relevant window handle associated with this |
| specific IHelpNotifyEvent. |
| controlId - Returns the resource ID of the control that was selected. |
------------------------------------------------------------------------------*/
IWindowHandle
windowHandle ( ) const;
unsigned short
controlId ( ) const;
};
/*----------------------------------------------------------------------------*/
/* Resume compiler default packing. */
/*----------------------------------------------------------------------------*/
#pragma pack()
#endif // _IHELPEVT_