summaryrefslogtreecommitdiff
path: root/plugins/IEView/src/TemplateHTMLBuilder.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2020-06-08 20:48:50 +0300
committerGeorge Hazan <ghazan@miranda.im>2020-06-08 20:48:57 +0300
commitb4d1e68688b1fe2d8e040c4b48ebe0f7b34bacc0 (patch)
treeef4f442d05d0e1508df8b7d5bc04c412d2ddc9e0 /plugins/IEView/src/TemplateHTMLBuilder.cpp
parentb660ea46cb4746bf2d8738fbd6a0574ec87ef7e0 (diff)
fixes #2434 (IEView не отображается поле %fileDesc%, но при этом заменяется поле %text% при указании описания файла при передаче)
Diffstat (limited to 'plugins/IEView/src/TemplateHTMLBuilder.cpp')
-rw-r--r--plugins/IEView/src/TemplateHTMLBuilder.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/IEView/src/TemplateHTMLBuilder.cpp b/plugins/IEView/src/TemplateHTMLBuilder.cpp
index 91ec9309ff..23698c65b0 100644
--- a/plugins/IEView/src/TemplateHTMLBuilder.cpp
+++ b/plugins/IEView/src/TemplateHTMLBuilder.cpp
@@ -357,13 +357,13 @@ void TemplateHTMLBuilder::appendEventTemplate(IEView *view, IEVIEWEVENT *event,
if (tszNick != nullptr)
szNickOut = encodeUTF8(event->hContact, szRealProto, tszNick, ENF_NAMESMILEYS, true);
- IEVIEWEVENTDATA* eventData = event->eventData;
+ IEVIEWEVENTDATA *eventData = event->eventData;
for (int eventIdx = 0; eventData != nullptr && (eventIdx < event->count || event->count == -1); eventData = eventData->next, eventIdx++) {
if (eventData->iType == IEED_EVENT_MESSAGE || eventData->iType == IEED_EVENT_STATUSCHANGE || eventData->iType == IEED_EVENT_FILE || eventData->iType == IEED_EVENT_SYSTEM) {
CMStringA str;
bool isSent = (eventData->dwFlags & IEEDF_SENT) != 0;
bool isRTL = (eventData->dwFlags & IEEDF_RTL) && tmpm->isRTL();
- bool isHistory = (eventData->time < (DWORD)getStartedTime() && (eventData->dwFlags & IEEDF_READ || eventData->dwFlags & IEEDF_SENT));
+ bool isHistory = (eventData->time < (DWORD)getStartedTime() && (eventData->dwFlags &IEEDF_READ || eventData->dwFlags & IEEDF_SENT));
bool isGroupBreak = true;
if ((getFlags(protoSettings) & Options::LOG_GROUP_MESSAGES) && eventData->dwFlags == LOWORD(getLastEventType())
&& eventData->iType == IEED_EVENT_MESSAGE && HIWORD(getLastEventType()) == IEED_EVENT_MESSAGE
@@ -395,6 +395,7 @@ void TemplateHTMLBuilder::appendEventTemplate(IEView *view, IEVIEWEVENT *event,
szText = encodeUTF8(event->hContact, eventData->szText.w, ENF_ALL, isSent);
else
szText = encodeUTF8(event->hContact, eventData->szText.a, event->codepage, ENF_ALL, isSent);
+
if (eventData->dwFlags & IEEDF_UNICODE_TEXT2)
szFileDesc = encodeUTF8(event->hContact, eventData->szText2.w, 0, isSent);
else