summaryrefslogtreecommitdiff
path: root/plugins/Clist_modern/src/modern_cachefuncs.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Clist_modern/src/modern_cachefuncs.cpp')
-rw-r--r--plugins/Clist_modern/src/modern_cachefuncs.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/plugins/Clist_modern/src/modern_cachefuncs.cpp b/plugins/Clist_modern/src/modern_cachefuncs.cpp
index e9ae405c35..dd8ecdaa3d 100644
--- a/plugins/Clist_modern/src/modern_cachefuncs.cpp
+++ b/plugins/Clist_modern/src/modern_cachefuncs.cpp
@@ -310,19 +310,16 @@ int GetStatusName(TCHAR *text, int text_size, ClcCacheEntry *pdnce, BOOL xstatus
}
// Get Status name
- {
- TCHAR *tmp = (TCHAR *)CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, (WPARAM)nStatus, GSMDF_TCHAR);
- lstrcpyn(text, tmp, text_size);
- //CopySkipUnprintableChars(text, dbv.pszVal, text_size-1);
- if (text[0] != '\0')
- return 1;
+ TCHAR *tmp = pcli->pfnGetStatusModeDescription(nStatus, 0);
+ if (tmp && *tmp) {
+ _tcsncpy_s(text, text_size, tmp, _TRUNCATE);
+ return 1;
}
// Get XStatusName
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);
db_free(&dbv);