summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Weimer <wishmaster51@googlemail.com>2014-03-16 17:28:30 +0000
committerTobias Weimer <wishmaster51@googlemail.com>2014-03-16 17:28:30 +0000
commit5a4d314be374f22b605800492ee30a5387321b6c (patch)
tree8522c7ce71f1b3aa3a1ee12cd9792fe942f534da
parent5dda582b4d67be1387011eafca84da0e8a12d9af (diff)
translation fixes
git-svn-id: http://svn.miranda-ng.org/main/trunk@8636 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--plugins/Clist_modern/src/modern_clistmenus.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/plugins/Clist_modern/src/modern_clistmenus.cpp b/plugins/Clist_modern/src/modern_clistmenus.cpp
index d0b21ac07e..fdbb006717 100644
--- a/plugins/Clist_modern/src/modern_clistmenus.cpp
+++ b/plugins/Clist_modern/src/modern_clistmenus.cpp
@@ -92,7 +92,7 @@ static IconItem iconList[] =
{ LPGEN("Contact rate High"), "Rate4", IDI_FAVORITE_3 }
};
-static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM lParam)
+static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM)
{
BYTE bContactRate = db_get_b(hContact, "CList", "Rate", 0);
if ( bContactRate > SIZEOF(rates)-1)
@@ -104,15 +104,17 @@ static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM lParam)
mi.icolibItem = iconList[bContactRate].hIcolib;
mi.pszPopupName = (char *)-1;
mi.position = 0;
+ mi.flags = CMIF_ROOTPOPUP | CMIF_TCHAR;
if (!bContactRate)
mi.ptszName = FAVMENUROOTNAME;
else {
- int bufsize = (lstrlen(FAVMENUROOTNAME)+lstrlen(rates[bContactRate])+15)*sizeof(TCHAR);
+ TCHAR *str1 = TranslateTS(FAVMENUROOTNAME), *str2 = TranslateTS(rates[bContactRate]);
+ int bufsize = (lstrlen(str1)+lstrlen(str2)+15)*sizeof(TCHAR);
TCHAR *name = (TCHAR*)_alloca(bufsize);
- mir_sntprintf(name, bufsize/sizeof(TCHAR), _T("%s (%s)"),FAVMENUROOTNAME,rates[bContactRate]);
+ mir_sntprintf(name, bufsize/sizeof(TCHAR), _T("%s (%s)"),str1,str2);
mi.ptszName = name;
+ mi.flags |= CMIF_KEEPUNTRANSLATED;
}
- mi.flags = CMIF_ROOTPOPUP | CMIF_TCHAR;
if (!hFavoriteContactMenu)
hFavoriteContactMenu = Menu_AddContactMenuItem(&mi);
else {