home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
ICLUI.ZIP
/
HELLO5
/
AHELLOW5.HPP
< prev
next >
Wrap
Text File
|
1993-03-06
|
6KB
|
87 lines
#ifndef AHELLOWINDOW_HPP
#define AHELLOWINDOW_HPP
/******************************************************************************/
/* HELLO WORLD SAMPLE PROGRAM - Version 5: Class Header (AHELLOW5.HPP) */
/* */
/* COPYRIGHT: Copyright (C) International Business Machines Corp., 1992,1993. */
/* */
/* DISCLAIMER OF WARRANTIES: */
/* The following [enclosed] code is sample code created by IBM */
/* Corporation. This sample code is not part of any standard IBM product */
/* and is provided to you solely for the purpose of assisting you in the */
/* development of your applications. The code is provided "AS IS", */
/* without warranty of any kind. IBM shall not be liable for any damages */
/* arising out of your use of the sample code, even if they have been */
/* advised of the possibility of such damages. */
/******************************************************************************/
// NOTE: WE RECOMMEND USING A FIXED SPACE FONT TO LOOK AT THE SOURCE
#include <iframe.hpp> //Include IFrameWindow Class Header
#include <icmdhdr.hpp> //Include ICommandEvent & ICommandHandler v3
#include <iselhdr.hpp> //Include ISelectHandler v5
#include <ihelphdr.hpp> //Include IHelpHandler v5
class ATextDialog; //Define the ATextDialog Class v4
class AEarthWindow; //Define the AEarthWindow Class v5
//**************************************************************************
// Class: AHelloWindow *
// *
// Purpose: Main Window for C++ Hello World sample application *
// It is a subclass of IFrameWindow, ICommandHandler and * v3
// ISelectHandler (Processing List Box Selection) * v5
// *
//**************************************************************************
class AHelloWindow : public IFrameWindow,
public ICommandHandler, //v3
public ISelectHandler //v5
{
public: //Define the Public Information
AHelloWindow(unsigned long windowId); //Constructor for this class
protected: //Define Protected Member v3
virtual Boolean setupButtons(); //Setup Buttons v4
virtual Boolean setupClient(); //Setup Client Window v5
virtual Boolean setupHelp(); //Setup Help .
virtual Boolean setupInfoArea() ; //Setup Information Area .
virtual Boolean setupMenuBar(); //Setup Menu Bar .
virtual Boolean setupStatusArea(); //Setup Status Area v5
virtual Boolean setText(const char* text);//Set Text using String v5
virtual Boolean selected(IControlEvent& evt); //v5
Boolean command(ICommandEvent& cmdEvent); //v3
private: //Define Private Information
IStaticText * hello; //Hello contains "Hello, World" text
IInfoArea * infoArea; //Define an Information Area v2
// Control to create an information .
// area beneath the client area v2
IStaticText * statusLine; //Status Line at top of client window v3
IMenuBar * menuBar; //Define Menu Bar v3
ATextDialog * textDialog; //Define Text Dialog v4
IPushButton * leftButton; //Define Left Button .
IPushButton * centerButton; //Define Center Button .
IPushButton * rightButton; //Define Right Button v4
IHelpWindow * help; //Define Help Window v5
AEarthWindow * earthWindow; //Define earthWindow v5
ISplitCanvas * clientWindow; //Define canvas as a Split Canvas v5
ISplitCanvas * helloCanvas; //Define hello canvas v5
IListBox * listBox; //Define ListBox v5
};
//************************************************************************** v5
// Class: AHelpHandler * .
// * .
// Purpose: Subclass of IHelpHandler so that the correct keys help * .
// panel can be displayed when keys help is requested. * .
// * .
//************************************************************************** .
class AHelpHandler: public IHelpHandler// .
{ // .
protected: //Define Protected Member .
virtual Boolean // .
keysHelpId(IEvent& evt); //Override this function .
}; //v5
#endif