#include <Application.h>
Public Member Functions | |
int | Init (const char *title) |
Function to initialize the object Application. | |
int | Init (const char *title, Uint16 w, Uint16 h, Uint8 bpp=32, bool window=true, int frequency=DEFAULT_FREQUENCY, int format=DEFAULT_FORMAT, int nchannels=DEFAULT_NCHANNELS, int chunksize=DEFAULT_CHUNKSIZE) |
Function to initialize the object Application. | |
int | InitFromLua (const char *file, const char *fileDPF=NULL) |
Function to initialize the object Application. | |
void | Release (void) |
Function to release the object Application. | |
void | Draw (void) |
Function to draw all the controls of the application. | |
bool | Update (void) |
Function to update all the controls of the application. | |
void | PushUpDialog (const Dialog *dialog) |
Function to push up a dialog in the application. | |
void | Exit (void) |
Exit the application. | |
Uint32 | GetTime (void) |
Get the number of milliseconds since the library initialization. | |
void | Delay (Uint32 ms) |
Wait a specified number of milliseconds before returning. | |
SDL_KEY_EVENT | GetKeyDown (void) |
Get the key down function of the control. | |
SDL_KEY_EVENT | GetKeyUp (void) |
Get the key up function of the control. | |
SDL_MOUSEMOTION_EVENT | GetMouseMotion (void) |
Get the mouse motion function of the control. | |
SDL_MOUSEBUTTON_EVENT | GetMouseButtonDown (void) |
Get the mouse button down function of the control. | |
SDL_MOUSEBUTTON_EVENT | GetMouseButtonUp (void) |
Get the mouse button up function of the control. | |
void | SetKeyDown (SDL_KEY_EVENT val) |
Set the key down function of the control. | |
void | SetKeyUp (SDL_KEY_EVENT val) |
Set the key up function of the control. | |
void | SetMouseMotion (SDL_MOUSEMOTION_EVENT val) |
Set the mouse motion function of the control. | |
void | SetMouseButtonDown (SDL_MOUSEBUTTON_EVENT val) |
Set the mouse button down function of the control. | |
void | SetMouseButtonUp (SDL_MOUSEBUTTON_EVENT val) |
Set the mouse button up function of the control. | |
SDL_Surface * | GetMousePointer (void) |
Get the mouse pointer of the application. | |
const char * | GetTitle (void) |
Get the title of the application. | |
const char * | GetIcon (void) |
Get the icon of the application. | |
bool | GetRenderBack (void) |
Get the render back state of the application. | |
SDL_Surface * | GetPicture (void) |
Get the picture of the application. | |
SDL_Rect * | GetActRect (void) |
Get the actual rect of the picture. | |
Uint32 | GetBackColor (void) |
Get the back color of the application. | |
bool | GetQuit (void) |
Get the quit state of the application. | |
lua_State * | GetLua (void) |
Get the quit state of the application. | |
Control * | GetActiveControl (void) |
Get the active control of the application. | |
Uint32 | GetInterval (void) |
Get the interval of the application's double click. | |
int | GetWidth (void) |
Get the width of the application. | |
int | GetHeight (void) |
Get the height of the application. | |
void | SetMousePointer (SDL_Surface *val) |
Set the mouse pointer of the application. | |
void | SetTitle (const char *val) |
Set the title of the application. | |
SDL_Surface * | SetIcon (const char *val) |
Set the icon of the application. | |
SDL_Surface * | SetIcon (const char *dpf, const char *val) |
Set the icon of the application. | |
void | SetRenderBack (bool val) |
Set the render back state of the application. | |
void | SetPicture (SDL_Surface *val) |
Set the picture of the application. | |
void | SetActRect (SDL_Rect *val) |
Set the actual rect of the picture. | |
void | SetBackColor (Uint32 val) |
Set the back color of the application. | |
void | SetInterval (Uint32 val) |
Set the interval of the application's double click. | |
void | NoActiveControl (void) |
Set the active control of the application to NULL. | |
Static Public Member Functions | |
static Application * | GetInstance (void) |
Function to obtain the instance of Application. | |
Public Attributes | |
SkinsManager | Skins |
Object to handle the skins of the controls. | |
ListControls | List |
List for the controls (please don't add here the dialogs). | |
ListControls | DialogList |
List for the dialogs (please don't add other kind of controls). | |
ResourcesManager | Resources |
Loaded resources of the application. |
int Motoko::Application::Init | ( | const char * | title, | |
Uint16 | w, | |||
Uint16 | h, | |||
Uint8 | bpp = 32 , |
|||
bool | window = true , |
|||
int | frequency = DEFAULT_FREQUENCY , |
|||
int | format = DEFAULT_FORMAT , |
|||
int | nchannels = DEFAULT_NCHANNELS , |
|||
int | chunksize = DEFAULT_CHUNKSIZE | |||
) |
Function to initialize the object Application.
title | Title of the application. | |
w | Width of the application. | |
h | Height of the application. | |
bpp | Bits per pixel of the application. | |
window | Window mode activated (true) or fullscreen (false). | |
frequency | Frequency of the audio system. | |
format | Format of the audio system. | |
nchannels | Number of channels of the audio system. | |
chunksize | Chunk size of the audio system. |
int Motoko::Application::Init | ( | const char * | title | ) |
Function to initialize the object Application.
title | Title of the application. |
int Motoko::Application::InitFromLua | ( | const char * | file, | |
const char * | fileDPF = NULL | |||
) |
Function to initialize the object Application.
file | Path of the lua file. | |
fileDPF | Container with the lua file. |
void Motoko::Application::Release | ( | void | ) |