Level H Engine
Static Public Member Functions | Static Private Attributes | List of all members
UIManager Class Reference

Contains static variables and functions for use with UI manager. More...

#include <UIManager.h>

Collaboration diagram for UIManager:
Collaboration graph

Static Public Member Functions

static void deleteAllUI ()
 A static function to delete all the UI. More...
 
static void deleteAllButtons ()
 A static function to delete all the buttons. More...
 
static void deleteButton (std::string id)
 A static function to delete the button. More...
 
static std::string initialiseButton (std::string buttonImage, std::string buttonHeldSprite, Vec2 inPos, Vec2 inDim)
 A static function to initialise a button and scale it. More...
 
static std::string initialiseButton (std::string buttonImage, std::string buttonHeldSprite, Vec2 inPos)
 A static function to initialise a button. More...
 
static ButtongetButton (std::string id)
 A static function to get a button. More...
 

Static Private Attributes

static std::unordered_map< std::string, Button * > buttons
 The loaded buttons. More...
 

Detailed Description

Contains static variables and functions for use with UI manager.

Member Function Documentation

◆ deleteAllButtons()

void UIManager::deleteAllButtons ( )
static

A static function to delete all the buttons.

Here is the caller graph for this function:

◆ deleteAllUI()

void UIManager::deleteAllUI ( )
static

A static function to delete all the UI.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ deleteButton()

static void UIManager::deleteButton ( std::string  id)
inlinestatic

A static function to delete the button.

Parameters
idThe ID of the file.
Here is the call graph for this function:

◆ getButton()

static Button* UIManager::getButton ( std::string  id)
inlinestatic

A static function to get a button.

Parameters
idThe ID of the file.
Here is the caller graph for this function:

◆ initialiseButton() [1/2]

std::string UIManager::initialiseButton ( std::string  buttonImage,
std::string  buttonHeldSprite,
Vec2  inPos,
Vec2  inDim 
)
static

A static function to initialise a button and scale it.

Parameters
buttonImageA path to the image of the button.
buttonHeldSpriteA path to the held image of the button.
posThe position.
dimThe dimensions.
Returns
The ID of the loaded file.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ initialiseButton() [2/2]

std::string UIManager::initialiseButton ( std::string  buttonImage,
std::string  buttonHeldSprite,
Vec2  inPos 
)
static

A static function to initialise a button.

Parameters
buttonHeldSpriteA path to the held image of the button.
posThe position.
Returns
The ID of the loaded file.
Here is the call graph for this function:

Member Data Documentation

◆ buttons

std::unordered_map< std::string, Button * > UIManager::buttons
staticprivate

The loaded buttons.


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