Colobot
|
Public Member Functions | |
void | Init () override |
Performs platform-specific initialization. More... | |
SystemDialogResult | SystemDialog (SystemDialogType type, const std::string &title, const std::string &message) override |
Displays a system dialog. More... | |
std::string | GetSaveDir () override |
Returns the save dir location. More... | |
std::string | GetEnvVar (const std::string &name) override |
Returns the environment variable with the given name or an empty string if it does not exist. More... | |
bool | OpenPath (const std::string &path) override |
Opens a path with default file browser. More... | |
bool | OpenWebsite (const std::string &url) override |
Opens a website with default web browser. More... | |
![]() | |
virtual void | Init ()=0 |
Performs platform-specific initialization. More... | |
virtual SystemDialogResult | SystemDialog (SystemDialogType, const std::string &title, const std::string &message)=0 |
Displays a system dialog. More... | |
TEST_VIRTUAL SystemDialogResult | ConsoleSystemDialog (SystemDialogType type, const std::string &title, const std::string &message) |
Displays a fallback system dialog using console. More... | |
TEST_VIRTUAL TimeUtils::TimeStamp | GetCurrentTimeStamp () |
Returns a time stamp associated with current time. More... | |
virtual std::string | GetBasePath () |
Returns the path where the executable binary is located (ends with the path separator) More... | |
virtual std::string | GetDataPath () |
Returns the data path (containing textures, levels, helpfiles, etc) More... | |
virtual std::string | GetLangPath () |
Returns the translations path. More... | |
virtual std::string | GetSaveDir () |
Returns the save dir location. More... | |
virtual std::string | GetEnvVar (const std::string &name) |
Returns the environment variable with the given name or an empty string if it does not exist. More... | |
virtual bool | OpenPath (const std::string &path) |
Opens a path with default file browser. More... | |
virtual bool | OpenWebsite (const std::string &url) |
Opens a website with default web browser. More... | |
void | Usleep (int usecs) |
Sleep for given amount of microseconds. More... | |
Static Public Member Functions | |
static std::string | UTF8_Encode (const std::wstring &wstr) |
Converts a wide Unicode string to an UTF8 string. More... | |
static std::wstring | UTF8_Decode (const std::string &str) |
Converts an UTF8 string to a wide Unicode String. More... | |
![]() | |
static std::unique_ptr< CSystemUtils > | Create () |
Creates system utils for specific platform. More... | |
|
overridevirtual |
Performs platform-specific initialization.
Implements CSystemUtils.
|
overridevirtual |
Displays a system dialog.
Implements CSystemUtils.
|
overridevirtual |
Returns the save dir location.
Reimplemented from CSystemUtils.
|
overridevirtual |
Returns the environment variable with the given name or an empty string if it does not exist.
Reimplemented from CSystemUtils.
|
overridevirtual |
|
overridevirtual |
Opens a website with default web browser.
Reimplemented from CSystemUtils.
|
static |
Converts a wide Unicode string to an UTF8 string.
|
static |
Converts an UTF8 string to a wide Unicode String.