Mana
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | List of all members
WindowContainer Class Reference

A window container. More...

#include <windowcontainer.h>

Inheritance diagram for WindowContainer:
Container Viewport

Public Member Functions

void logic () override
 Do GUI logic.
 
void draw (gcn::Graphics *graphics) override
 Adds debug drawing.
 
void scheduleDelete (gcn::Widget *widget)
 Schedule a widget for deletion.
 
void adjustAfterResize (int oldScreenWidth, int oldScreenHeight)
 Ensures that all visible windows are on the screen after the screen has been resized.
 
- Public Member Functions inherited from Container
 Container ()
 
 ~Container () override
 
void drawFrame (gcn::Graphics *graphics) override
 

Private Member Functions

void debugDraw (gcn::Graphics *graphics)
 Draws the outlines of the container and all its children.
 
bool widgetIsVisible (gcn::Widget *widget)
 Returns whether the widget is visible and part of the hierarchy.
 

Private Attributes

std::set< gcn::Widget * > mScheduledDeletions
 Set of widgets that are scheduled to be deleted.
 

Additional Inherited Members

- Protected Member Functions inherited from Container
LayoutgetLayout ()
 Gets the layout handler for this container.
 
LayoutCellplace (int x, int y, gcn::Widget *wg, int w=1, int h=1)
 Adds a widget to the container and sets it at given cell.
 
ContainerPlacer getPlacer (int x, int y)
 Returns a proxy for adding widgets in an inner table of the layout.
 

Detailed Description

A window container.

This container adds functionality for more convenient widget (windows in particular) destruction.

Definition at line 34 of file windowcontainer.h.

Member Function Documentation

◆ adjustAfterResize()

void WindowContainer::adjustAfterResize ( int  oldScreenWidth,
int  oldScreenHeight 
)

Ensures that all visible windows are on the screen after the screen has been resized.

Definition at line 53 of file windowcontainer.cpp.

◆ debugDraw()

void WindowContainer::debugDraw ( gcn::Graphics *  graphics)
private

Draws the outlines of the container and all its children.

Definition at line 61 of file windowcontainer.cpp.

◆ draw()

void WindowContainer::draw ( gcn::Graphics *  graphics)
override

Adds debug drawing.

Definition at line 40 of file windowcontainer.cpp.

◆ logic()

void WindowContainer::logic ( )
override

Do GUI logic.

This functions adds automatic deletion of objects that volunteered to be deleted.

Definition at line 31 of file windowcontainer.cpp.

◆ scheduleDelete()

void WindowContainer::scheduleDelete ( gcn::Widget *  widget)

Schedule a widget for deletion.

It will be deleted at the start of the next logic update.

Definition at line 48 of file windowcontainer.cpp.

◆ widgetIsVisible()

bool WindowContainer::widgetIsVisible ( gcn::Widget *  widget)
private

Returns whether the widget is visible and part of the hierarchy.

Definition at line 111 of file windowcontainer.cpp.

Member Data Documentation

◆ mScheduledDeletions

std::set<gcn::Widget *> WindowContainer::mScheduledDeletions
private

Set of widgets that are scheduled to be deleted.

Definition at line 71 of file windowcontainer.h.


The documentation for this class was generated from the following files: