summaryrefslogtreecommitdiff
path: root/plugins/Clist_modern/src/modern_clcitems.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-11-10 16:38:37 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-11-10 16:38:37 +0000
commit5bedc7c584439c4b2cf01e605c044746674003e4 (patch)
tree3103c3c16254e7ed9c42a3fcf908562a8b6dfbc8 /plugins/Clist_modern/src/modern_clcitems.cpp
parent9239c8833dbe27e5257b043a7ca2e90288a9fedb (diff)
- fix for uninitialized variables;
- code cleaning in clists git-svn-id: http://svn.miranda-ng.org/main/trunk@2274 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_modern/src/modern_clcitems.cpp')
-rw-r--r--plugins/Clist_modern/src/modern_clcitems.cpp17
1 files changed, 11 insertions, 6 deletions
diff --git a/plugins/Clist_modern/src/modern_clcitems.cpp b/plugins/Clist_modern/src/modern_clcitems.cpp
index 48ff30bc2e..898e0d4507 100644
--- a/plugins/Clist_modern/src/modern_clcitems.cpp
+++ b/plugins/Clist_modern/src/modern_clcitems.cpp
@@ -265,20 +265,25 @@ void * AddTempGroup(HWND hwnd,struct ClcData *dat,const TCHAR *szName,DWORD flag
void cli_AddContactToTree(HWND hwnd,struct ClcData *dat,HANDLE hContact,int updateTotalCount,int checkHideOffline)
{
- ClcGroup *group;
- ClcContact * cont;
pClcCacheEntry cacheEntry = (pClcCacheEntry)pcli->pfnGetCacheEntry(hContact);
- if (dat->IsMetaContactsEnabled && cacheEntry && cacheEntry->m_cache_nHiddenSubcontact) return; //contact should not be added
- if ( !dat->IsMetaContactsEnabled && cacheEntry && g_szMetaModuleName && !mir_strcmp(cacheEntry->m_cache_cszProto,g_szMetaModuleName)) return;
+ if (dat->IsMetaContactsEnabled && cacheEntry && cacheEntry->m_cache_nHiddenSubcontact)
+ return; //contact should not be added
+
+ if ( !dat->IsMetaContactsEnabled && cacheEntry && g_szMetaModuleName && !mir_strcmp(cacheEntry->m_cache_cszProto,g_szMetaModuleName))
+ return;
+
corecli.pfnAddContactToTree(hwnd,dat,hContact,updateTotalCount,checkHideOffline);
- if (FindItem(hwnd,dat,hContact,&cont,&group,NULL,FALSE))
+
+ ClcGroup *group;
+ ClcContact *cont;
+ if ( FindItem(hwnd,dat,hContact,&cont,&group,NULL,FALSE))
_LoadDataToContact(cont, group, dat, hContact);
return;
}
void cli_DeleteItemFromTree(HWND hwnd,HANDLE hItem)
{
- struct ClcData *dat = (struct ClcData *) GetWindowLongPtr(hwnd, 0);
+ ClcData *dat = (struct ClcData *) GetWindowLongPtr(hwnd, 0);
ClearRowByIndexCache();
corecli.pfnDeleteItemFromTree(hwnd, hItem);