diff options
author | George Hazan <george.hazan@gmail.com> | 2013-03-02 13:38:53 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-03-02 13:38:53 +0000 |
commit | 3d26dc75537137d829cc388abe0b9fe4b2df0d9d (patch) | |
tree | 61ee0925fca5f4d9ab10ef3ea5a8e14f213a1a11 /protocols/AimOscar/src/avatars.cpp | |
parent | 6d46936f5711c2b927b88f4c93cf1431a776bbba (diff) |
unicode folders custom names (gotten from szName by default, as usual)
git-svn-id: http://svn.miranda-ng.org/main/trunk@3835 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/AimOscar/src/avatars.cpp')
-rw-r--r-- | protocols/AimOscar/src/avatars.cpp | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/protocols/AimOscar/src/avatars.cpp b/protocols/AimOscar/src/avatars.cpp index f8017684a7..f54a6b8d41 100644 --- a/protocols/AimOscar/src/avatars.cpp +++ b/protocols/AimOscar/src/avatars.cpp @@ -172,7 +172,7 @@ void CAimProto::init_custom_folders(void) TCHAR AvatarsFolder[MAX_PATH];
mir_sntprintf(AvatarsFolder, SIZEOF(AvatarsFolder), _T("%%miranda_avatarcache%%\\%S"), m_szModuleName);
- hAvatarsFolder = FoldersRegisterCustomPathT("Avatars", m_szModuleName, AvatarsFolder);
+ hAvatarsFolder = FoldersRegisterCustomPathT("Avatars", m_szModuleName, AvatarsFolder, m_tszUserName);
init_cst_fld_ran = true;
}
@@ -185,15 +185,8 @@ int CAimProto::get_avatar_filename(HANDLE hContact, TCHAR* pszDest, size_t cbLen TCHAR* path = (TCHAR*)alloca(cbLen * sizeof(TCHAR));
if (hAvatarsFolder == NULL || FoldersGetCustomPathT(hAvatarsFolder, path, (int)cbLen, _T("")))
- {
- TCHAR *tmpPath = Utils_ReplaceVarsT(_T("%miranda_avatarcache%"));
- TCHAR *tszModuleName = mir_a2t(m_szModuleName);
- tPathLen = mir_sntprintf(pszDest, cbLen, _T("%s\\%s"), tmpPath, tszModuleName);
- mir_free(tszModuleName);
- mir_free(tmpPath);
- }
- else
- {
+ tPathLen = mir_sntprintf(pszDest, cbLen, _T("%s\\%S"), (TCHAR*)VARST( _T("%miranda_avatarcache%")), m_szModuleName);
+ else {
_tcscpy(pszDest, path);
tPathLen = _tcslen(pszDest);
}
|