diff options
author | George Hazan <ghazan@miranda.im> | 2019-03-02 12:32:44 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-03-02 12:32:55 +0300 |
commit | 931a7dc1ac0dbc7e6c1083583ced915e572f5b47 (patch) | |
tree | 9fe9a6448d44030e26aa7107ce16044ed413e0d0 /protocols/CurrencyRates/src/CreateFilePath.cpp | |
parent | dd7d9954042254e66e3bbbec7195c6be8b1a0663 (diff) |
all protocols (even virtual ones) moved to the Protocols folder
Diffstat (limited to 'protocols/CurrencyRates/src/CreateFilePath.cpp')
-rw-r--r-- | protocols/CurrencyRates/src/CreateFilePath.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/protocols/CurrencyRates/src/CreateFilePath.cpp b/protocols/CurrencyRates/src/CreateFilePath.cpp new file mode 100644 index 0000000000..71490432a9 --- /dev/null +++ b/protocols/CurrencyRates/src/CreateFilePath.cpp @@ -0,0 +1,17 @@ +#include "StdAfx.h" + +tstring CreateFilePath(const tstring &rsName) +{ + wchar_t szPath[_MAX_PATH]; + ::GetModuleFileName(g_plugin.getInst(), szPath, _MAX_PATH); + + wchar_t* p = wcsrchr(szPath, '\\'); + if (p) + *p = 0; + + tstring s(rsName); + FixInvalidChars(s); + tostringstream o; + o << szPath << L"\\CurrencyRates\\" << s; + return o.str(); +}
\ No newline at end of file |