diff options
author | George Hazan <george.hazan@gmail.com> | 2015-05-27 12:49:25 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-05-27 12:49:25 +0000 |
commit | 5db9b527e95334d103a7804f31fe95f97b5687a7 (patch) | |
tree | d3926c45164e86d57f0282760c303b1c4fd4578e /plugins/TabSRMM/src/msglog.cpp | |
parent | c014bd45e4761fd8da881e4f726022fc918624b2 (diff) |
ansi functionality removed from tabSRMM
only utf8 remained
git-svn-id: http://svn.miranda-ng.org/main/trunk@13856 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TabSRMM/src/msglog.cpp')
-rw-r--r-- | plugins/TabSRMM/src/msglog.cpp | 33 |
1 files changed, 4 insertions, 29 deletions
diff --git a/plugins/TabSRMM/src/msglog.cpp b/plugins/TabSRMM/src/msglog.cpp index 689892e4b0..35a9a75544 100644 --- a/plugins/TabSRMM/src/msglog.cpp +++ b/plugins/TabSRMM/src/msglog.cpp @@ -421,7 +421,7 @@ static char* Template_CreateRTFFromDbEvent(TWindowData *dat, MCONTACT hContact, dat->cache->updateStats(TSessionStats::SET_LAST_RCV, mir_strlen((char *)dbei.pBlob));
TCHAR *formatted = NULL;
- TCHAR *msg = DbGetEventTextT(&dbei, dat->codePage);
+ TCHAR *msg = DbGetEventTextT(&dbei, CP_UTF8);
if (!msg) {
mir_free(dbei.pBlob);
return NULL;
@@ -1175,6 +1175,7 @@ void TSAPI StreamInEvents(HWND hwndDlg, MEVENT hDbEventFirst, int count, int fAp const char *pszService;
IEVIEWEVENT event = { 0 };
event.cbSize = sizeof(IEVIEWEVENT);
+ event.hContact = dat->hContact;
if (dat->hwndIEView != NULL) {
event.pszProto = dat->szProto;
event.hwnd = dat->hwndIEView;
@@ -1185,13 +1186,8 @@ void TSAPI StreamInEvents(HWND hwndDlg, MEVENT hDbEventFirst, int count, int fAp pszService = MS_HPP_EG_EVENT;
}
- event.hContact = dat->hContact;
- event.dwFlags = (dat->dwFlags & MWF_LOG_RTL) ? IEEF_RTL : 0;
- if (dat->sendMode & SMODE_FORCEANSI) {
- event.dwFlags |= IEEF_NO_UNICODE;
- event.codepage = dat->codePage;
- }
- else event.codepage = 0;
+ if (dat->dwFlags & MWF_LOG_RTL)
+ event.dwFlags = IEEF_RTL;
if (!fAppend) {
event.iType = IEE_CLEAR_LOG;
@@ -1320,24 +1316,3 @@ void TSAPI StreamInEvents(HWND hwndDlg, MEVENT hDbEventFirst, int count, int fAp EnableWindow(GetDlgItem(hwndDlg, IDC_QUOTE), dat->hDbEventLast != NULL);
mir_free(streamData.buffer);
}
-
-// NLS functions (for unicode version only) encoding stuff..
-static BOOL CALLBACK LangAddCallback(LPTSTR str)
-{
- UINT cp = _ttoi(str);
- for (int i = 0; i < SIZEOF(cpTable); i++)
- if (cpTable[i].cpId == cp) {
- AppendMenu(PluginConfig.g_hMenuEncoding, MF_STRING, cp, TranslateTS(cpTable[i].cpName));
- break;
- }
-
- return TRUE;
-}
-
-void TSAPI BuildCodePageList()
-{
- PluginConfig.g_hMenuEncoding = CreateMenu();
- AppendMenu(PluginConfig.g_hMenuEncoding, MF_STRING, 500, TranslateT("Use default codepage"));
- AppendMenuA(PluginConfig.g_hMenuEncoding, MF_SEPARATOR, 0, 0);
- EnumSystemCodePages(LangAddCallback, CP_INSTALLED);
-}
|