Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

ASC_PG_App Class Reference

#include <paradialog.h>

Inheritance diagram for ASC_PG_App:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 ASC_PG_App (const ASCString &themeName)
bool InitScreen (int w, int h, int depth=0, Uint32 flags=SDL_SWSURFACE|SDL_HWPALETTE)
 Initialize the screen.
void reloadTheme ()
int Run ()
 Run the applications main eventloop.
void Quit ()
 Exit the main eventloop.
bool isFullscreen ()
bool toggleFullscreen ()
void setIcon (const ASCString &filename)
void processEvent ()
bool enableLegacyEventHandling (bool use)
bool queueWidgetForDeletion (PG_Widget *widget)
 ~ASC_PG_App ()
void SetNewScreenSurface (SDL_Surface *surface)

Static Public Attributes

static const int mapDisplayID = 2
static const int mainScreenID = 1

Protected Member Functions

bool eventQuit (int id, PG_MessageObject *widget, unsigned long data)
 Overridable Eventhandler for a SDL_QuitEvent message.
void eventIdle ()

Constructor & Destructor Documentation

ASC_PG_App::ASC_PG_App const ASCString themeName  ) 
 

Definition at line 124 of file paradialog.cpp.

References PG_FileArchive::AddArchive(), displayLogMessage(), PG_Application::EnableAppIdleCalls(), PG_FileArchive::EnableSymlinks(), eventSupplier, getSearchPath(), idleEvent, CGameOptions::Instance(), PG_LOG_ERR, reloadTheme(), PG_LineEdit::SetBlinkingTime(), PG_Application::SetEventSupplier(), PG_Application::SetHighlightingTag(), setMouseUpdateFlag(), PG_Application::sigAppIdle, and signalQuit().

ASC_PG_App::~ASC_PG_App  ) 
 

Definition at line 402 of file paradialog.cpp.

References shutdownASCGraphicSubsystem().


Member Function Documentation

bool ASC_PG_App::enableLegacyEventHandling bool  use  ) 
 

Definition at line 380 of file paradialog.cpp.

References setEventRouting().

Referenced by Run().

void ASC_PG_App::eventIdle  )  [protected, virtual]
 

Reimplemented from PG_Application.

Definition at line 209 of file paradialog.cpp.

References PG_Application::eventIdle(), PG_Application::GetScreen(), redrawScreen, PG_Application::UpdateRect(), and PG_Widget::UpdateScreen().

bool ASC_PG_App::eventQuit int  id,
PG_MessageObject widget,
unsigned long  data
[protected, virtual]
 

Overridable Eventhandler for a SDL_QuitEvent message.

The default implementation returns 'false' which indicates that this message is not processed by this object.

Parameters:
id id of the sending widget
widget pointer to the widget
data event specific data
Returns:
Notifies the message pump if this message is processed by this object or it should be routed to the next message receiver.

Reimplemented from PG_Application.

Definition at line 203 of file paradialog.cpp.

References PG_Application::eventQuit(), and PG_MessageObject::sigQuit.

bool ASC_PG_App::InitScreen int  w,
int  h,
int  depth = 0,
Uint32  flags = SDL_SWSURFACE|SDL_HWPALETTE
 

Initialize the screen.

Parameters:
w screenwidth in pixels
h screenheight in pixels
depth screendepth in bits per pixel
flags PG_ screen initialization flags

Reimplemented from PG_Application.

Definition at line 353 of file paradialog.cpp.

References MessagingHubBase::Error, MessagingHubBase::FatalError, PG_Application::GetScreen(), MessagingHubBase::InfoMessage, initASCGraphicSubsystem(), PG_Application::InitScreen(), Surface::SetScreen(), and MessagingHubBase::Warning.

Referenced by main().

bool ASC_PG_App::isFullscreen  )  [inline]
 

Definition at line 95 of file paradialog.h.

void ASC_PG_App::processEvent  ) 
 

Definition at line 386 of file paradialog.cpp.

References PG_Application::GetEventSupplier(), and PG_Application::PumpIntoEventQueue().

bool ASC_PG_App::queueWidgetForDeletion PG_Widget widget  ) 
 

Definition at line 167 of file paradialog.cpp.

References PG_MessageObject::sigDelete.

void ASC_PG_App::Quit  ) 
 

Exit the main eventloop.

Reimplemented from PG_Application.

Definition at line 196 of file paradialog.cpp.

References PG_Application::Quit(), and PG_MessageObject::sigQuit.

void ASC_PG_App::reloadTheme  ) 
 

Definition at line 373 of file paradialog.cpp.

References fatalError(), and PG_Application::LoadTheme().

Referenced by ASC_PG_App().

int ASC_PG_App::Run  ) 
 

Run the applications main eventloop.

If theaded is false this function will exit when the eventloop quits (MSG_QUIT). If threaded is true it will return immediately and a thread processing events is started. CAUTION: Threaded eventloops are unsuported under Win32 (windows specific behavior)

Reimplemented from PG_Application.

Definition at line 394 of file paradialog.cpp.

References enableLegacyEventHandling(), and PG_Application::Run().

void ASC_PG_App::setIcon const ASCString filename  ) 
 

Definition at line 184 of file paradialog.cpp.

References tnstream::reading, and SDL_RWFromStream().

Referenced by main().

void ASC_PG_App::SetNewScreenSurface SDL_Surface *  surface  ) 
 

Definition at line 225 of file paradialog.cpp.

References PG_Application::SetScreen().

Referenced by toggleFullscreen().

bool ASC_PG_App::toggleFullscreen  ) 
 

Definition at line 231 of file paradialog.cpp.

References PG_Application::GetScreen(), queueOperation(), SetNewScreenSurface(), and PG_Widget::UpdateScreen().


Member Data Documentation

const int ASC_PG_App::mainScreenID = 1 [static]
 

Definition at line 86 of file paradialog.h.

Referenced by ASC_MainScreenWidget::ASC_MainScreenWidget(), and MainScreenWidget::setup().

const int ASC_PG_App::mapDisplayID = 2 [static]
 

Definition at line 85 of file paradialog.h.

Referenced by MainScreenWidget::setup(), and Weathercast::Weathercast().


The documentation for this class was generated from the following files:
Generated on Tue Jun 24 02:16:08 2008 for Advanced Strategic Command by  doxygen 1.4.2