mirror of
https://gitlab.com/Mr_Goldberg/goldberg_emulator.git
synced 2025-12-15 16:38:25 +01:00
Some refactoring. Added a define for the default callresult/callback timeout.
This commit is contained in:
parent
25d53b6542
commit
beffb89bda
2 changed files with 22 additions and 13 deletions
24
dll/base.cpp
24
dll/base.cpp
|
|
@ -191,6 +191,19 @@ std::string get_lib_path() {
|
|||
}
|
||||
#endif
|
||||
|
||||
std::string get_full_lib_path()
|
||||
{
|
||||
std::string program_path;
|
||||
#if defined(STEAM_WIN32)
|
||||
char DllPath[MAX_PATH] = {0};
|
||||
GetModuleFileName((HINSTANCE)&__ImageBase, DllPath, _countof(DllPath));
|
||||
program_path = DllPath;
|
||||
#else
|
||||
program_path = get_lib_path();
|
||||
#endif
|
||||
return program_path;
|
||||
}
|
||||
|
||||
std::string get_full_program_path()
|
||||
{
|
||||
std::string env_program_path = get_env_variable("SteamAppPath");
|
||||
|
|
@ -203,15 +216,8 @@ std::string get_full_program_path()
|
|||
}
|
||||
|
||||
std::string program_path;
|
||||
#if defined(STEAM_WIN32)
|
||||
char DllPath[MAX_PATH] = {0};
|
||||
GetModuleFileName((HINSTANCE)&__ImageBase, DllPath, _countof(DllPath));
|
||||
program_path = DllPath;
|
||||
#else
|
||||
program_path = get_lib_path();
|
||||
#endif
|
||||
program_path = program_path.substr(0, program_path.rfind(PATH_SEPARATOR)).append(PATH_SEPARATOR);
|
||||
return program_path;
|
||||
program_path = get_full_lib_path();
|
||||
return program_path.substr(0, program_path.rfind(PATH_SEPARATOR)).append(PATH_SEPARATOR);
|
||||
}
|
||||
|
||||
std::string get_current_path()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue