home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fish 5
/
FreshFish_July-August1994.bin
/
bbs
/
gnu
/
aplusplus-1.01-src.lha
/
src
/
amiga
/
aplusplus-1.01
/
include
/
aplusplus
/
intuition
/
GWindow.h
< prev
next >
Wrap
C/C++ Source or Header
|
1994-05-09
|
3KB
|
69 lines
#ifndef APP_GWindow_H
#define APP_GWindow_H
/******************************************************************************
**
** C++ Class Library for the Amiga© system software.
**
** Copyright (C) 1994 by Armin Vogt ** EMail: armin@uni-paderborn.de
** All Rights Reserved.
**
** $VER: apphome:APlusPlus/intuition/GWindow.h 1.04 (04.05.94) $
**
******************************************************************************/
#include <APlusPlus/intuition/WindowCV.h>
#include <APlusPlus/graphics/DrawArea.h>
#include <APlusPlus/intuition/GadgetCV.h>
/******************************************************************************************
» GWindow class «
This Window class combines all Intuition supported gadget types including BOOPSI and,
additionally to GWindow class, GadTools. All gadget types may be used together in
one GWindow. Furthermore a DrawArea is provided for the inner window box.
******************************************************************************************/
class GWindow : public WindowCV, public DrawArea
{
// find the GadgetCV object to a Gadget structure, for instance received with an IntuiMessage
friend GadgetCV;
private:
GadgetCV *activeGadget; // gadget that is actual to get all IDCMP messages without an IAddress.
GadgetCV *defaultGadget; // may be defined to receive IDCMP messages without gadget reference.
struct Gadget *firstUserGad; // holds the beginning of the list of user gadgets.
// Remember: The first gadgets in a window's list after being opened are the system gadgets!
struct Gadget *GT_context; // context data for Gadtools.
struct Gadget *GT_last; // tail of the linked list of GadTools gadgets during the ON_NEWSIZE proc.
FontC screenFont;
FontC defaultFont;
// preset IDCMP callbacks
void On_GADGETDOWN(const IntuiMessageC *);
void On_GADGETUP(const IntuiMessageC *);
void On_SIZEVERIFY(const IntuiMessageC *);
void On_NEWSIZE(const IntuiMessageC *);
void On_REFRESHWINDOW(const IntuiMessageC *);
void default_IMsgCallback(const IntuiMessageC *imsg);
protected:
void handleIntuiMsg(const IntuiMessageC*); // inherited from WindowCV
public:
GWindow(IntuiObject *owner,AttrList& attrs);
~GWindow();
void refreshGList() { On_NEWSIZE(NULL); } // redraw all gadgets
const FontC& getScreenFont() { return screenFont; } // this is the Screen Text font from Preferences
const FontC& getDefaultFont() { return defaultFont; } // and this the System Default font from Preferences
void setActiveGadget(GadgetCV *newActive);
// force a certain Gadget to become the active one, that is the one that
// receives all undirected IDCMP messages.
// 'newActive' may be NULL to deactivate itself
};
#endif