diff options
Diffstat (limited to 'protocols/Yahoo')
-rw-r--r-- | protocols/Yahoo/src/avatar.cpp | 27 | ||||
-rw-r--r-- | protocols/Yahoo/src/proto.cpp | 1 | ||||
-rw-r--r-- | protocols/Yahoo/src/proto.h | 4 |
3 files changed, 1 insertions, 31 deletions
diff --git a/protocols/Yahoo/src/avatar.cpp b/protocols/Yahoo/src/avatar.cpp index adb05e8e08..2e3c71cacf 100644 --- a/protocols/Yahoo/src/avatar.cpp +++ b/protocols/Yahoo/src/avatar.cpp @@ -607,34 +607,9 @@ void CYahooProto::request_avatar(const char* who) else LOG(("Avatar Not Available for: %s Last Check: %ld Current: %ld (Flood Check in Effect)", who, last_chk, cur_time));
}
-void CYahooProto::InitCustomFolders(void)
-{
- if (InitCstFldRan)
- return;
-
- InitCstFldRan = true;
-
- TCHAR AvatarsFolder[MAX_PATH];
- mir_sntprintf(AvatarsFolder, MAX_PATH, _T("%%miranda_avatarcache%%\\%S"), m_szModuleName);
- hYahooAvatarsFolder = FoldersRegisterCustomPathT(LPGEN("Avatars"), m_szModuleName, AvatarsFolder, m_tszUserName);
-}
-
void CYahooProto::GetAvatarFileName(HANDLE hContact, TCHAR* pszDest, int cbLen, int type)
{
- size_t tPathLen;
-
- InitCustomFolders();
-
- TCHAR* path = ( TCHAR* )alloca( sizeof(TCHAR)*( cbLen+1 ));
- if ( hYahooAvatarsFolder != NULL && !FoldersGetCustomPathT( hYahooAvatarsFolder, path, (int)cbLen, _T("")))
- {
- _tcscpy( pszDest, path );
- tPathLen = _tcslen( pszDest );
- } else {
- TCHAR *tmpPath = Utils_ReplaceVarsT( _T("%miranda_avatarcache%"));
- tPathLen = mir_sntprintf(pszDest, cbLen, _T("%s\\%S"), tmpPath, m_szModuleName);
- mir_free(tmpPath);
- }
+ int tPathLen = mir_sntprintf(pszDest, cbLen, _T("%s\\%S"), VARST( _T("%miranda_avatarcache%")), m_szModuleName);
if ( _taccess(pszDest, 0))
CreateDirectoryTreeT(pszDest);
diff --git a/protocols/Yahoo/src/proto.cpp b/protocols/Yahoo/src/proto.cpp index 4bf27e2cbf..4769e91e22 100644 --- a/protocols/Yahoo/src/proto.cpp +++ b/protocols/Yahoo/src/proto.cpp @@ -39,7 +39,6 @@ CYahooProto::CYahooProto( const char* aProtoName, const TCHAR* aUserName ) : LoadYahooServices();
IconsInit();
- InitCustomFolders();
}
CYahooProto::~CYahooProto()
diff --git a/protocols/Yahoo/src/proto.h b/protocols/Yahoo/src/proto.h index ea358abdbd..4124737890 100644 --- a/protocols/Yahoo/src/proto.h +++ b/protocols/Yahoo/src/proto.h @@ -298,10 +298,6 @@ private: HGENMENU mainMenuRoot;
HGENMENU hShowProfileMenuItem;
HGENMENU menuItemsAll[ 8 ];
-
- HANDLE hYahooAvatarsFolder;
- bool InitCstFldRan;
- void InitCustomFolders(void);
};
extern LIST<CYahooProto> g_instances;
|