summaryrefslogtreecommitdiff
path: root/plugins/Clist_modern/src/modern_cachefuncs.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-06-29 20:46:04 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-06-29 20:46:04 +0000
commit9d5df5c08b85b0537d1bc0d26055a08fb7ff4c4a (patch)
tree46ee217da3641c98c3c6659fe9c9acb048658c0a /plugins/Clist_modern/src/modern_cachefuncs.cpp
parent80c568f8938f2fef76bf7a54179278e17d327d90 (diff)
- unused fields and functions removed;
- code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@9623 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_modern/src/modern_cachefuncs.cpp')
-rw-r--r--plugins/Clist_modern/src/modern_cachefuncs.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/plugins/Clist_modern/src/modern_cachefuncs.cpp b/plugins/Clist_modern/src/modern_cachefuncs.cpp
index e8b27596a8..2caf524487 100644
--- a/plugins/Clist_modern/src/modern_cachefuncs.cpp
+++ b/plugins/Clist_modern/src/modern_cachefuncs.cpp
@@ -290,16 +290,16 @@ int GetStatusName(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xstatus
BOOL noAwayMsg = FALSE;
BOOL noXstatus = FALSE;
// Hide status text if Offline /// no offline
- WORD nStatus = pdnce___GetStatus( pdnce );
+ WORD nStatus = pdnce___GetStatus(pdnce);
if ((nStatus == ID_STATUS_OFFLINE || nStatus == 0) && g_CluiData.bRemoveAwayMessageForOffline) noAwayMsg = TRUE;
if (nStatus == ID_STATUS_OFFLINE || nStatus == 0) noXstatus = TRUE;
text[0] = '\0';
// Get XStatusName
- if (!noAwayMsg && !noXstatus && xstatus_has_priority && pdnce->hContact && pdnce->m_cache_cszProto) {
- DBVARIANT dbv = {0};
+ if (!noAwayMsg && !noXstatus && xstatus_has_priority && pdnce->hContact && pdnce->m_cache_cszProto) {
+ DBVARIANT dbv = { 0 };
if (!db_get_ts(pdnce->hContact, pdnce->m_cache_cszProto, "XStatusName", &dbv)) {
//lstrcpyn(text, dbv.pszVal, text_size);
- CopySkipUnprintableChars(text, dbv.ptszVal, text_size-1);
+ CopySkipUnprintableChars(text, dbv.ptszVal, text_size - 1);
db_free(&dbv);
if (text[0] != '\0')
@@ -316,9 +316,9 @@ int GetStatusName(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xstatus
// Get XStatusName
if (!noAwayMsg && !noXstatus && !xstatus_has_priority && pdnce->hContact && pdnce->m_cache_cszProto) {
- DBVARIANT dbv = {0};
+ DBVARIANT dbv = { 0 };
if (!db_get_ts(pdnce->hContact, pdnce->m_cache_cszProto, "XStatusName", &dbv)) {
- CopySkipUnprintableChars(text, dbv.ptszVal, text_size-1);
+ CopySkipUnprintableChars(text, dbv.ptszVal, text_size - 1);
db_free(&dbv);
if (text[0] != '\0')
@@ -333,17 +333,17 @@ int GetStatusName(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xstatus
* Get Listening to information
*/
-void GetListeningTo(TCHAR *text, int text_size, ClcCacheEntry *pdnce)
+void GetListeningTo(TCHAR *text, int text_size, ClcCacheEntry *pdnce)
{
- DBVARIANT dbv = {0};
- WORD wStatus = pdnce___GetStatus( pdnce );
+ DBVARIANT dbv = { 0 };
+ WORD wStatus = pdnce___GetStatus(pdnce);
text[0] = _T('\0');
if (wStatus == ID_STATUS_OFFLINE || wStatus == 0)
return;
if (!db_get_ts(pdnce->hContact, pdnce->m_cache_cszProto, "ListeningTo", &dbv)) {
- CopySkipUnprintableChars(text, dbv.ptszVal, text_size-1);
+ CopySkipUnprintableChars(text, dbv.ptszVal, text_size - 1);
db_free(&dbv);
}
}
@@ -353,11 +353,11 @@ void GetListeningTo(TCHAR *text, int text_size, ClcCacheEntry *pdnce)
* -1 for XStatus, 1 for Status
*/
-int GetStatusMessage(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xstatus_has_priority)
+int GetStatusMessage(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xstatus_has_priority)
{
- DBVARIANT dbv = {0};
+ DBVARIANT dbv = { 0 };
BOOL noAwayMsg = FALSE;
- WORD wStatus = pdnce___GetStatus( pdnce );
+ WORD wStatus = pdnce___GetStatus(pdnce);
text[0] = '\0';
// Hide status text if Offline /// no offline
@@ -367,7 +367,7 @@ int GetStatusMessage(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xst
// Try to get XStatusMsg
if (!db_get_ts(pdnce->hContact, pdnce->m_cache_cszProto, "XStatusMsg", &dbv)) {
//lstrcpyn(text, dbv.pszVal, text_size);
- CopySkipUnprintableChars(text, dbv.ptszVal, text_size-1);
+ CopySkipUnprintableChars(text, dbv.ptszVal, text_size - 1);
db_free(&dbv);
if (text[0] != '\0')
@@ -379,7 +379,7 @@ int GetStatusMessage(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xst
if (pdnce->hContact && text[0] == '\0') {
if (!db_get_ts(pdnce->hContact, "CList", "StatusMsg", &dbv)) {
//lstrcpyn(text, dbv.pszVal, text_size);
- CopySkipUnprintableChars(text, dbv.ptszVal, text_size-1);
+ CopySkipUnprintableChars(text, dbv.ptszVal, text_size - 1);
db_free(&dbv);
if (text[0] != '\0')
@@ -392,7 +392,7 @@ int GetStatusMessage(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xst
// Try to get XStatusMsg
if (!db_get_ts(pdnce->hContact, pdnce->m_cache_cszProto, "XStatusMsg", &dbv)) {
//lstrcpyn(text, dbv.pszVal, text_size);
- CopySkipUnprintableChars(text, dbv.ptszVal, text_size-1);
+ CopySkipUnprintableChars(text, dbv.ptszVal, text_size - 1);
db_free(&dbv);
if (text[0] != '\0')
@@ -517,9 +517,9 @@ void Cache_GetFirstLineText(ClcData *dat, ClcContact *contact)
return;
ClcCacheEntry *pdnce = pcli->pfnGetCacheEntry(contact->hContact);
- TCHAR *name = pcli->pfnGetContactDisplayName(contact->hContact,0);
+ TCHAR *name = pcli->pfnGetContactDisplayName(contact->hContact, 0);
if (dat->first_line_append_nick && (!dat->force_in_dialog)) {
- DBVARIANT dbv = {0};
+ DBVARIANT dbv = { 0 };
if (!db_get_ts(pdnce->hContact, pdnce->m_cache_cszProto, "Nick", &dbv)) {
TCHAR nick[SIZEOF(contact->szText)];
lstrcpyn(nick, dbv.ptszVal, SIZEOF(contact->szText));
@@ -537,8 +537,8 @@ void Cache_GetFirstLineText(ClcData *dat, ClcContact *contact)
else lstrcpyn(contact->szText, name, SIZEOF(contact->szText));
if (!dat->force_in_dialog) {
- struct SHORTDATA data = {0};
- Sync(CLUI_SyncGetShortData,(WPARAM)pcli->hwndContactTree,(LPARAM)&data);
+ struct SHORTDATA data = { 0 };
+ Sync(CLUI_SyncGetShortData, (WPARAM)pcli->hwndContactTree, (LPARAM)&data);
contact->ssText.ReplaceSmileys(&data, pdnce, contact->szText, dat->first_line_draw_smileys);
}
}
@@ -604,7 +604,7 @@ void Cache_GetThirdLineText(struct SHORTDATA *dat, ClcCacheEntry *pdnce)
void RemoveTag(TCHAR *to, TCHAR *tag)
{
- TCHAR * st = to;
+ TCHAR *st = to;
int len = (int)_tcslen(tag);
int lastsize = (int)_tcslen(to)+1;
while (st = _tcsstr(st,tag)) {