summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Weimer <wishmaster51@googlemail.com>2014-03-15 17:32:44 +0000
committerTobias Weimer <wishmaster51@googlemail.com>2014-03-15 17:32:44 +0000
commit20a2d3dc9f8ab2e2e8833a1c83cf2dd30f25aa8e (patch)
tree5ec3badf526bc6349eee5cadcb866eab32e5c185
parent67bfe77f9b0868b94c3d4094b646cc7561b098e6 (diff)
* Fix for displaying custom events in Scriver (fixes #553)
git-svn-id: http://svn.miranda-ng.org/main/trunk@8626 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--plugins/Scriver/src/msglog.cpp22
1 files changed, 9 insertions, 13 deletions
diff --git a/plugins/Scriver/src/msglog.cpp b/plugins/Scriver/src/msglog.cpp
index f2798c44b4..d04744ad01 100644
--- a/plugins/Scriver/src/msglog.cpp
+++ b/plugins/Scriver/src/msglog.cpp
@@ -173,7 +173,7 @@ EventData* getEventFromDB(struct SrmmWindowData *dat, MCONTACT hContact, HANDLE
else if (dbei.eventType == EVENTTYPE_JABBER_CHATSTATES || dbei.eventType == EVENTTYPE_JABBER_PRESENCE)
db_event_markRead(hContact, hDbEvent);
- evt->eventType = evt->custom ? EVENTTYPE_MESSAGE : dbei.eventType;
+ evt->eventType = dbei.eventType;
evt->dwFlags = (dbei.flags & DBEF_READ ? IEEDF_READ : 0) | (dbei.flags & DBEF_SENT ? IEEDF_SENT : 0) | (dbei.flags & DBEF_RTL ? IEEDF_RTL : 0);
evt->dwFlags |= IEEDF_UNICODE_TEXT | IEEDF_UNICODE_NICK | IEEDF_UNICODE_TEXT2;
@@ -637,10 +637,7 @@ static char* CreateRTFFromEvent(struct SrmmWindowData *dat, EventData *evt, stru
i = LOGICON_MSG_IN;
break;
- case EVENTTYPE_JABBER_CHATSTATES:
- case EVENTTYPE_JABBER_PRESENCE:
- case EVENTTYPE_URL:
- case EVENTTYPE_FILE:
+ default:
i = LOGICON_MSG_NOTICE;
break;
}
@@ -713,14 +710,6 @@ static char* CreateRTFFromEvent(struct SrmmWindowData *dat, EventData *evt, stru
AppendToBuffer(&buffer, &bufferEnd, &bufferAlloced, "%s: ", SetToStyle(evt->dwFlags & IEEDF_SENT ? MSGFONTID_MYCOLON : MSGFONTID_YOURCOLON));
}
switch (evt->eventType) {
- case EVENTTYPE_MESSAGE:
- if (gdat->flags & SMF_MSGONNEWLINE && showColon)
- AppendToBuffer(&buffer, &bufferEnd, &bufferAlloced, "\\line");
-
- style = evt->dwFlags & IEEDF_SENT ? MSGFONTID_MYMSG : MSGFONTID_YOURMSG;
- AppendWithCustomLinks(evt, style, &buffer, &bufferEnd, &bufferAlloced);
- break;
-
case EVENTTYPE_JABBER_CHATSTATES:
case EVENTTYPE_JABBER_PRESENCE:
case EVENTTYPE_URL:
@@ -759,6 +748,13 @@ static char* CreateRTFFromEvent(struct SrmmWindowData *dat, EventData *evt, stru
AppendTToBuffer(&buffer, &bufferEnd, &bufferAlloced, _T(")"));
}
break;
+ default:
+ if (gdat->flags & SMF_MSGONNEWLINE && showColon)
+ AppendToBuffer(&buffer, &bufferEnd, &bufferAlloced, "\\line");
+
+ style = evt->dwFlags & IEEDF_SENT ? MSGFONTID_MYMSG : MSGFONTID_YOURMSG;
+ AppendWithCustomLinks(evt, style, &buffer, &bufferEnd, &bufferAlloced);
+ break;
}
if (dat->isMixed)
AppendToBuffer(&buffer, &bufferEnd, &bufferAlloced, "\\par");