[DEV] add get application name API
This commit is contained in:
parent
500e2ebfd6
commit
b02a75a7b8
@ -112,3 +112,7 @@ void etk::init(int _argc, const char** _argv) {
|
|||||||
}
|
}
|
||||||
TK_INFO("E-TK system init (END)");
|
TK_INFO("E-TK system init (END)");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::string etk::getApplicationName() {
|
||||||
|
return etk::FSNodeGetApplicationName();
|
||||||
|
}
|
||||||
|
@ -9,6 +9,8 @@
|
|||||||
#ifndef __ETK_H__
|
#ifndef __ETK_H__
|
||||||
#define __ETK_H__
|
#define __ETK_H__
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
|
||||||
namespace etk {
|
namespace etk {
|
||||||
/**
|
/**
|
||||||
* @brief Initialize etk
|
* @brief Initialize etk
|
||||||
@ -16,6 +18,12 @@ namespace etk {
|
|||||||
* @param[in] _argv List of arguments
|
* @param[in] _argv List of arguments
|
||||||
*/
|
*/
|
||||||
void init(int _argc, const char** _argv);
|
void init(int _argc, const char** _argv);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief Get application name.
|
||||||
|
* @return The application name
|
||||||
|
*/
|
||||||
|
std::string getApplicationName();
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -150,6 +150,9 @@ static std::string baseRunPathInHome = "/";
|
|||||||
static std::string baseFolderCache = "~/.tmp/cache/"; // Temporary data (can be removed the next time)
|
static std::string baseFolderCache = "~/.tmp/cache/"; // Temporary data (can be removed the next time)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
std::string etk::FSNodeGetApplicationName() {
|
||||||
|
return baseApplName;
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef __TARGET_OS__Android
|
#ifdef __TARGET_OS__Android
|
||||||
static etk::Archive* s_APKArchive = nullptr;
|
static etk::Archive* s_APKArchive = nullptr;
|
||||||
|
@ -25,6 +25,12 @@ namespace etk {
|
|||||||
namespace etk {
|
namespace etk {
|
||||||
void setArgZero(const std::string& _val);
|
void setArgZero(const std::string& _val);
|
||||||
std::string simplifyPath(std::string _input);
|
std::string simplifyPath(std::string _input);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief Get application name.
|
||||||
|
* @return The application name
|
||||||
|
*/
|
||||||
|
std::string FSNodeGetApplicationName();
|
||||||
/**
|
/**
|
||||||
* List of Type that a node can have (this wrap some type that not exist on Windows)
|
* List of Type that a node can have (this wrap some type that not exist on Windows)
|
||||||
*/
|
*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user