Planeshift
pePawsManager Class Reference

#include <pepawsmanager.h>

Public Member Functions

 pePawsManager (iObjectRegistry *objectReg, const char *skin)
 
void ReloadStyles ()
 
virtual ~pePawsManager (void)
 
- Public Member Functions inherited from PawsManager
void AddObjectView (pawsWidget *widget)
 Adds an object view to the array. More...
 
bool ApplyStyle (const char *name, iDocumentNode *target)
 Applies PAWS style to XML node. More...
 
void CreateWarningBox (const char *message, pawsWidget *notify=NULL, bool modal=true)
 Creates a warning box with the supplied text. More...
 
pawsWidgetCreateWidget (const char *factoryName)
 Create a new widget. More...
 
pawsWidgetCreateWidget (const char *factoryName, const pawsWidget *origin)
 Create a new widget using copy constructor. More...
 
void CreateYesNoBox (const char *message, pawsWidget *notify=NULL, bool modal=true, bool translate=true)
 Creates a YesNo box with the supplied text. More...
 
void Draw ()
 Draw the main widget and the mouse last. More...
 
void Draw3D ()
 Draw 3D parts of the widgets. More...
 
MathEnvironmentExtraScriptVars ()
 
pawsWidgetFindWidget (const char *name, bool complain=true)
 Locate a widget by name. More...
 
pawsWidgetGetCurrentFocusedWidget ()
 Returns the widget that is focused. More...
 
pawsWidgetGetDragDropWidget ()
 Gets the widget that is being drag'n'dropped over screen with the mouse. More...
 
iEventNameRegistry * GetEventNameRegistry ()
 Get the event name registry. More...
 
bool GetFocusOverridesControls ()
 Returns true if the current focused widget needs to override all controls. More...
 
float GetFontFactor ()
 Gets the factor the font should be adjusted by for proper fontsize based on resolution. More...
 
iGraphics2D * GetGraphics2D ()
 Returns the 2D renderer. More...
 
iGraphics3D * GetGraphics3D ()
 Returns the 3D renderer. More...
 
psLocalizationGetLocalization ()
 Returns the psLocalization object: More...
 
pawsMainWidgetGetMainWidget ()
 Returns the main widget. More...
 
pawsWidgetGetModalWidget ()
 Returns modal widget. More...
 
pawsMouseGetMouse ()
 Returns the mouse. More...
 
iObjectRegistry * GetObjectRegistry ()
 Returns the object registry. More...
 
pawsPrefManagerGetPrefs ()
 Returns the prefrence manager. More...
 
iPawsImageGetResizeImage ()
 Returns the resize button image. More...
 
iSoundManager * GetSoundManager ()
 Gets the soundManager. More...
 
pawsTextureManagerGetTextureManager ()
 Returns the texture manager. More...
 
bool getToolTipEnable ()
 returns tooltips enabled/disabled More...
 
bool getToolTipEnableBgColor ()
 returns tooltips brackground color More...
 
int getTooltipsColors (int element)
 returns one element of the TooltipsColors-array More...
 
csString getToolTipSkinPath ()
 returns the full path to the tooltips.xml in skin.zip More...
 
csString & getVFSPathToSkin ()
 
bool HandleEvent (iEvent &event)
 Process mouse and keyboard events. More...
 
csArray< iPAWSSubscriber * > ListSubscribers (const char *dataname)
 Return a list of all subscribers. More...
 
bool LoadChildWidgets (const char *widgetFile, csArray< pawsWidget * > &loadedWidgets)
 Loads widgets from a definition file without assigning a parent. More...
 
bool LoadObjectViews ()
 
bool LoadSkinDefinition (const char *zip)
 Loads a skin and loades unregistered resources. More...
 
bool LoadTooltips (const char *fileName)
 Loads the Tooltips config-file. More...
 
bool LoadWidget (const char *widgetFile)
 Loads a widget definition file. More...
 
pawsWidgetLoadWidget (iDocumentNode *widgetNode)
 Loads a widget from given XML node. More...
 
pawsWidgetLoadWidgetFromString (const char *widgetDefinition)
 Loads a widget definition from a string. More...
 
void MovingWidget (pawsWidget *moving)
 Let the window manager know that a widget is being moved. More...
 
void OnWidgetDeleted (pawsWidget *widget)
 pawsWidget destructor calls this so PawsManager can NULLify all its links to the widget. More...
 
void OnWidgetHidden (pawsWidget *widget)
 Remove focus and mouseover effect from widget if widget is hidden. More...
 
 PawsManager (iObjectRegistry *objectReg, const char *skin, const char *skinBase=NULL)
 
void Publish (const csString &dataname, PAWSData &data)
 Announce a change in a named element to all subscribers. More...
 
void Publish (const csString &dataname, const char *datavalue)
 Publish a string to all subscribers. More...
 
void Publish (const csString &dataname, bool datavalue)
 Publish a boolean value to all subscribers. More...
 
void Publish (const csString &dataname, int datavalue)
 Publish an int to all subscribers. More...
 
void Publish (const csString &dataname, unsigned int datavalue)
 Publish an unsigned int to all subscribers. More...
 
void Publish (const csString &dataname, float datavalue)
 Publish a float to all subscribers. More...
 
void Publish (const csString &dataname, const char *datavalue, int color)
 Publish a coloured string to all subscribers. More...
 
void Publish (const csString &dataname)
 Publish nothing to all subscribers. (Used for one-time named signals.) More...
 
void RegisterWidgetFactory (pawsWidgetFactory *factory)
 Add a new factory to the list that the manager knows about. More...
 
void RemoveObjectView (pawsWidget *widget)
 Removes an object view from the array. More...
 
bool RemoveWidget (const char *widgetName, bool complain)
 Remove the named widget from the mainwidget. More...
 
void ResizingWidget (pawsWidget *widget, int flags)
 Let the manager know that a widget is being resized. More...
 
void SetCurrentFocusedWidget (pawsWidget *widget)
 Give this widget focus. More...
 
void SetDragDropWidget (pawsWidget *dragDropWidget)
 Sets the widget that is being drag'n'dropped over screen with the mouse. More...
 
void SetMainWidget (pawsMainWidget *widg)
 Establish main widget. More...
 
void SetModalWidget (pawsWidget *widget)
 Make this widget modal. More...
 
void setToolTipEnable (bool state)
 changes tooltips enabled/disabled More...
 
void setToolTipEnableBgColor (bool state)
 changes tooltips backround enabled/disabled More...
 
void setTooltipsColors (int element, int param)
 transfers a value to the TooltipsColors-array More...
 
void Subscribe (const char *dataname, iPAWSSubscriber *listener)
 Subscribe to a named piece of data, so updates are received automatically. More...
 
csString Translate (const csString &orig)
 A shortcut - translation without need to call GetLocalization(). More...
 
void UnSubscribe (iPAWSSubscriber *listener)
 Unsubscribe the given subscriber. More...
 
void UseR2T (bool r2t)
 
bool UsingR2T () const
 
virtual ~PawsManager ()
 
- Public Member Functions inherited from Singleton< PawsManager >
 Singleton (PawsManager *ptr)
 
 Singleton (void)
 
 ~Singleton ()
 

Additional Inherited Members

- Static Public Member Functions inherited from Singleton< PawsManager >
static PawsManagerGetSingleton (void)
 
static PawsManagerGetSingletonPtr (void)
 
- Public Attributes inherited from PawsManager
bool ToolTipEnable
 Sets if the tooltip should be enable. More...
 
bool ToolTipEnableBgColor
 Sets if the tooltip should have a bgcolor. More...
 
int TooltipsColors [3]
 Array of tooltip colors. More...
 
- Protected Member Functions inherited from PawsManager
bool HandleDoubleClick (csMouseEventData &data)
 Process mouse double click events. More...
 
bool HandleKeyDown (iEvent &event)
 Process key down events. More...
 
bool HandleMouseDown (csMouseEventData &data)
 Process mouse down events. More...
 
bool HandleMouseMove (csMouseEventData &data)
 Process mouse movement events. More...
 
bool HandleMouseUp (csMouseEventData &data)
 Process mouse up events. More...
 
psPoint MouseLocation (iEvent &ev)
 
csPtr< iDocumentNode > ParseWidgetFile (const char *widgetFile)
 Parses given file and returns the <widget_description> tag of it. More...
 
void RegisterFactories ()
 Helper function to load standard factories. More...
 
- Protected Attributes inherited from PawsManager
pawsWidgetcurrentFocusedWidget
 The last widget that the mouse clicked on. ( Hence the focused one ). More...
 
pawsWidgetdragDropWidget
 The widget that is drag'n'dropped across the screen by the mouse. More...
 
MathEnvironment extraScriptVars
 
csPDelArray< pawsWidgetFactoryfactories
 An array of pointers to available factories. More...
 
bool focusOverridesControls
 Does the currentFocusedWidget take focus from the control system? More...
 
float fontFactor
 The font resizing factor for all widgets. More...
 
csRef< iGraphics2D > graphics2D
 Pointer to the Crystal Space iGraphics2D renderer used to display 2D graphics. More...
 
csRef< iGraphics3D > graphics3D
 Pointer to the Crystal Space iGraphics3D renderer used to display 3D graphics. More...
 
csRef< iTextureHandle > guiTexture
 Render texture for gui rendering. More...
 
bool hadKeyDown
 Flag for key down function. More...
 
csEventID KeyboardDown
 Shortcut for event key down. More...
 
csEventID KeyboardUp
 Shortcut for event key up. More...
 
pawsWidgetlastfadeWidget
 The actual widget that was last faded. More...
 
psLocalizationlocalization
 Localized file object registry. More...
 
pawsMainWidgetmainWidget
 The main handler widget. More...
 
pawsWidgetmodalWidget
 Current modal widget. More...
 
pawsMousemouse
 The mouse pointer. More...
 
csEventID MouseDoubleClick
 Shortcut for event mouse double click. More...
 
csEventID MouseDown
 Shortcut for event mouse down. More...
 
csEventID MouseMove
 Shortcut for event mouse move. More...
 
pawsWidgetmouseoverWidget
 The last widget that the mouse moved over. ( For alpha fade effects ). More...
 
csEventID MouseUp
 Shortcut for event mouse up. More...
 
pawsWidgetmovingWidget
 Current widget that is being moved. More...
 
csRef< iEventNameRegistry > nameRegistry
 For event parsing. More...
 
iObjectRegistry * objectReg
 The object registry. More...
 
csArray< pawsWidget * > objectViews
 Array of paws object view widgets;. More...
 
pawsPrefManagerprefs
 The preference/default manager. More...
 
bool render2texture
 Whether to use r2t for the gui. More...
 
csRef< iPawsImageresizeImg
 Resized image. More...
 
int resizingFlags
 The resize flags. More...
 
pawsWidgetresizingWidget
 Holds the widget that is being resized. More...
 
csRef< iSoundManager > soundManager
 planeshift's sound manager More...
 
pawsStylesstyles
 PAWS style definitions. More...
 
PAWSSubscriptionsHash subscriptions
 Table of subscriptions. More...
 
pawsTextureManagertextureManager
 The texture manager. More...
 
csTicks timeOver
 The time mouse has been over the last widget. More...
 
int tipDelay
 The time mouse has been over a widget before showing the tooltip. More...
 
csRef< iVFS > vfs
 Pointer to the Crystal Space iVFS file system. More...
 
csString vfsPathToSkin
 VFS Mount directory mapping to the specified skin zip file. More...
 
csRef< iDocumentSystem > xml
 Pointer to the Crystal Space iDocumentSystem. More...
 

Detailed Description

Definition at line 30 of file pepawsmanager.h.

Constructor & Destructor Documentation

pePawsManager::pePawsManager ( iObjectRegistry *  objectReg,
const char *  skin 
)
virtual pePawsManager::~pePawsManager ( void  )
virtual

Member Function Documentation

void pePawsManager::ReloadStyles ( )

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