#include <amigascreen.h>
Classes | |
struct | AmigaScreenFlags |
Public Types | |
enum | AmigaScreenFlagType { AMIGA_SCREEN_SHOW_FLIP = 0x0001, AMIGA_SCREEN_SHOW_DEPTH = 0x0002 } |
Public Member Functions | |
AmigaScreen (const WoopsiString &title, u32 flags, u32 screenFlags, GadgetStyle *style=NULL) | |
virtual void | setBorderless (bool isBorderless) |
virtual void | handleReleaseEvent (const GadgetEventArgs &e) |
virtual void | showFlipButton () |
virtual void | showDepthButton () |
virtual void | hideFlipButton () |
virtual void | hideDepthButton () |
virtual const bool | hasFlipButton () const |
virtual const bool | hasDepthButton () const |
Protected Member Functions | |
virtual void | drawBorder (GraphicsPort *port) |
virtual void | onClick (s16 x, s16 y) |
virtual | ~AmigaScreen () |
AmigaScreen (const AmigaScreen &amigaScreen) | |
Protected Attributes | |
DecorationGlyphButton * | _depthButton |
DecorationGlyphButton * | _flipButton |
AmigaScreenFlags | _screenFlags |
Class providing a screen with an Amiga-style title bar. Unlike the AmigaWindow class, the title bar in this class can be overlapped by child gadgets. Clicking and dragging the title bar causes the screen to drop down the DS' display, revealing any screens below it. The screen has depth swap and display flip buttons.
All gadgets should be a child/grandchild/etc of a screen except for other screens and the Woopsi instance.
WoopsiUI::AmigaScreen::AmigaScreen | ( | const WoopsiString & | title, | |
u32 | flags, | |||
u32 | screenFlags, | |||
GadgetStyle * | style = NULL | |||
) |
Constructor.
title | The screen's title. | |
flags | Bitmask specifying some setup values for the object. | |
screenFlags | Screen-specific setup bitmask. | |
style | The style that the gadget should use. If this is not specified, the gadget will use the values stored in the global defaultGadgetStyle object. The gadget will copy the properties of the style into its own internal style object. |
virtual WoopsiUI::AmigaScreen::~AmigaScreen | ( | ) | [inline, protected, virtual] |
Destructor.
WoopsiUI::AmigaScreen::AmigaScreen | ( | const AmigaScreen & | amigaScreen | ) | [inline, protected] |
Copy constructor is protected to prevent usage.
virtual void WoopsiUI::AmigaScreen::drawBorder | ( | GraphicsPort * | port | ) | [protected, virtual] |
Draw the area of this gadget that falls within the clipping region. Called by the redraw() function to draw all visible regions.
port | The GraphicsPort to draw to. |
Reimplemented from WoopsiUI::Screen.
virtual void WoopsiUI::AmigaScreen::handleReleaseEvent | ( | const GadgetEventArgs & | e | ) | [virtual] |
Handle events fired by decoration gadgets.
e | Event arguments to process. |
Reimplemented from WoopsiUI::GadgetEventHandler.
virtual const bool WoopsiUI::AmigaScreen::hasDepthButton | ( | ) | const [inline, virtual] |
Does the screen have a depth button?
virtual const bool WoopsiUI::AmigaScreen::hasFlipButton | ( | ) | const [inline, virtual] |
Does the screen have a flip button?
virtual void WoopsiUI::AmigaScreen::hideDepthButton | ( | ) | [virtual] |
Hides the depth button if it is hidden. Has no effect if the screen is borderless.
virtual void WoopsiUI::AmigaScreen::hideFlipButton | ( | ) | [virtual] |
Hides the flip button if it is visible. Has no effect if the screen is borderless.
virtual void WoopsiUI::AmigaScreen::onClick | ( | s16 | x, | |
s16 | y | |||
) | [protected, virtual] |
Starts the dragging system.
x | The x co-ordinate of the click. | |
y | The y co-ordinate of the click. |
Reimplemented from WoopsiUI::Gadget.
virtual void WoopsiUI::AmigaScreen::setBorderless | ( | bool | isBorderless | ) | [virtual] |
Sets this gadget's border state. Setting to false hides the title bar.
isBorderless | The border state. |
Reimplemented from WoopsiUI::Gadget.
virtual void WoopsiUI::AmigaScreen::showDepthButton | ( | ) | [virtual] |
Shows the depth button if it is hidden. Has no effect if the screen is borderless.
virtual void WoopsiUI::AmigaScreen::showFlipButton | ( | ) | [virtual] |
Shows the flip button if it is hidden. Has no effect if the screen is borderless.
DecorationGlyphButton* WoopsiUI::AmigaScreen::_depthButton [protected] |
Pointer to the screen's depth button
DecorationGlyphButton* WoopsiUI::AmigaScreen::_flipButton [protected] |
Pointer to the screen's flip button
AmigaScreenFlags WoopsiUI::AmigaScreen::_screenFlags [protected] |
AmigaScreen-specific flags