#include <MercuryTheme.h>
Collaboration diagram for MercuryThemeManager:
Public Member Functions | |
~MercuryThemeManager () | |
void | ReloadAllThemes () |
bool | GetMetric (const MString &sKey, const MString &sValue, MString &sData, int ttl=100) |
MString | GetMetricS (const MString &sKey, const MString &sValue, const MString &Default="") |
int | GetMetricI (const MString &sKey, const MString &sValue, int Default=0) |
float | GetMetricF (const MString &sKey, const MString &sValue, float Default=0) |
bool | GetMetricB (const MString &sKey, const MString &sValue, bool Default=false) |
bool | GetPathToFile (const MString &File, MString &Path) |
MString | GetPathToFile (const MString &Name) |
MString | GetPathToGraphic (const MString &Name) |
MString | GetPathToModel (const MString &Name) |
Private Attributes | |
MVector< MercuryTheme > * | m_vThemes |
Definition at line 30 of file MercuryTheme.h.
MercuryThemeManager::~MercuryThemeManager | ( | ) | [inline] |
Definition at line 33 of file MercuryTheme.h.
void MercuryThemeManager::ReloadAllThemes | ( | ) |
Reload all themes in the order found in Mercury.ini, under section [Options], value Themes. The first theme is the primary in search order. The default theme should be last.
Definition at line 19 of file MercuryTheme.cpp.
bool MercuryThemeManager::GetMetric | ( | const MString & | sKey, | |
const MString & | sValue, | |||
MString & | sData, | |||
int | ttl = 100 | |||
) |
Get a specific metric value from metrics, it returns the data via sData, and returns true if the value was found, false otherwise.
Definition at line 39 of file MercuryTheme.cpp.
MString MercuryThemeManager::GetMetricS | ( | const MString & | sKey, | |
const MString & | sValue, | |||
const MString & | Default = "" | |||
) |
Get a specific value from metrics and return it as a string, using default as the default return
Definition at line 75 of file MercuryTheme.cpp.
int MercuryThemeManager::GetMetricI | ( | const MString & | sKey, | |
const MString & | sValue, | |||
int | Default = 0 | |||
) |
Get a specific value from metrics and return it as a integer, using default as the default return
Definition at line 85 of file MercuryTheme.cpp.
float MercuryThemeManager::GetMetricF | ( | const MString & | sKey, | |
const MString & | sValue, | |||
float | Default = 0 | |||
) |
Get a specific value from metrics and return it as a floating point number, using default as the default return
Definition at line 90 of file MercuryTheme.cpp.
bool MercuryThemeManager::GetMetricB | ( | const MString & | sKey, | |
const MString & | sValue, | |||
bool | Default = false | |||
) |
Get a specific value from metrics and return it as a boolean, using default as the default return
Definition at line 95 of file MercuryTheme.cpp.
Get path to a file, in any theme. This will check to see if any of the themes have the file in order. If the file exists, it will put the path to the file (including the file) in Path and return true, else it will return false.
Definition at line 100 of file MercuryTheme.cpp.
Get path to file in the File/ folder
Definition at line 119 of file MercuryTheme.cpp.
Get the path to a specific graphic, check all themes for the graphic, and if none is found, return the path to the default missing image.
Definition at line 128 of file MercuryTheme.cpp.
Get the path to a specific model, check all themes for the graphic, and if none is found, return the path to the default missing model.
Definition at line 140 of file MercuryTheme.cpp.
MVector< MercuryTheme >* MercuryThemeManager::m_vThemes [private] |
Definition at line 60 of file MercuryTheme.h.