summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/AutoShutdown/src/watcher.cpp2
-rw-r--r--plugins/BasicHistory/src/EventList.cpp2
-rw-r--r--plugins/Boltun/src/boltun.cpp2
-rw-r--r--plugins/CmdLine/src/mimcmd_handlers.cpp2
-rw-r--r--plugins/HistoryLinkListPlus/src/linklist_fct.cpp6
-rw-r--r--plugins/HistoryPlusPlus/hpp_events.pas2
-rw-r--r--plugins/IEHistory/src/utils.cpp2
-rw-r--r--plugins/IEView/src/HTMLBuilder.cpp6
-rw-r--r--plugins/Msg_Export/src/utils.cpp4
-rw-r--r--plugins/NewEventNotify/src/popup.cpp4
-rw-r--r--plugins/NewStory/src/history_array.cpp6
-rw-r--r--plugins/NewStory/src/history_dlg.cpp4
-rw-r--r--plugins/Scriver/src/msgdialog.cpp2
-rw-r--r--plugins/Scriver/src/msglog.cpp2
-rw-r--r--plugins/TabSRMM/src/msgdialog.cpp2
-rw-r--r--plugins/TabSRMM/src/msglog.cpp6
-rw-r--r--plugins/TipperYM/src/subst.cpp2
-rw-r--r--plugins/Variables/src/parse_miranda.cpp2
-rw-r--r--plugins/wbOSD/src/events.cpp4
19 files changed, 31 insertions, 31 deletions
diff --git a/plugins/AutoShutdown/src/watcher.cpp b/plugins/AutoShutdown/src/watcher.cpp
index 271e619180..d290a65c78 100644
--- a/plugins/AutoShutdown/src/watcher.cpp
+++ b/plugins/AutoShutdown/src/watcher.cpp
@@ -72,7 +72,7 @@ static int MsgEventAdded(WPARAM, LPARAM hDbEvent)
DBVARIANT dbv;
if (!g_plugin.getWString("Message", &dbv)) {
ltrimw(rtrimw(dbv.pwszVal));
- ptrW wszMsg(DbEvent_GetTextW(&dbei, CP_ACP));
+ ptrW wszMsg(DbEvent_GetTextW(&dbei));
if (wszMsg != nullptr && wcsstr(wszMsg, dbv.pwszVal) != nullptr)
ShutdownAndStopWatcher(); /* msg with specified text recvd */
mir_free(dbv.pwszVal); /* does NULL check */
diff --git a/plugins/BasicHistory/src/EventList.cpp b/plugins/BasicHistory/src/EventList.cpp
index 031552102e..2be9c30110 100644
--- a/plugins/BasicHistory/src/EventList.cpp
+++ b/plugins/BasicHistory/src/EventList.cpp
@@ -443,7 +443,7 @@ std::wstring HistoryEventList::GetContactId()
static void GetMessageDescription(DBEVENTINFO *dbei, wchar_t* buf, int cbBuf)
{
- wchar_t *msg = DbEvent_GetTextW(dbei, CP_ACP);
+ wchar_t *msg = DbEvent_GetTextW(dbei);
wcsncpy_s(buf, cbBuf, msg ? msg : TranslateT("Invalid message"), _TRUNCATE);
buf[cbBuf - 1] = 0;
mir_free(msg);
diff --git a/plugins/Boltun/src/boltun.cpp b/plugins/Boltun/src/boltun.cpp
index beaee86406..7b691a29be 100644
--- a/plugins/Boltun/src/boltun.cpp
+++ b/plugins/Boltun/src/boltun.cpp
@@ -202,7 +202,7 @@ static int MessageEventAdded(WPARAM hContact, LPARAM hDbEvent)
if (Config.MarkAsRead)
db_event_markRead(hContact, hDbEvent);
- AnswerToContact(hContact, ptrW(DbEvent_GetTextW(&dbei, CP_ACP)));
+ AnswerToContact(hContact, ptrW(DbEvent_GetTextW(&dbei)));
return 0;
}
diff --git a/plugins/CmdLine/src/mimcmd_handlers.cpp b/plugins/CmdLine/src/mimcmd_handlers.cpp
index 1410c7c29a..e41ec820a4 100644
--- a/plugins/CmdLine/src/mimcmd_handlers.cpp
+++ b/plugins/CmdLine/src/mimcmd_handlers.cpp
@@ -1223,7 +1223,7 @@ void AddHistoryEvent(DBEVENTINFO *dbEvent, wchar_t *contact, PReply reply)
TimeZone_ToString(dbEvent->timestamp, "D, s", timestamp, _countof(timestamp));
wchar_t *sender = (dbEvent->flags & DBEF_SENT) ? TranslateT("[me]") : contact;
- wchar_t *message = DbEvent_GetTextW(dbEvent, CP_ACP);
+ wchar_t *message = DbEvent_GetTextW(dbEvent);
static wchar_t buffer[8192];
mir_snwprintf(buffer, L"[%S] %15s: %s", timestamp, sender, message);
diff --git a/plugins/HistoryLinkListPlus/src/linklist_fct.cpp b/plugins/HistoryLinkListPlus/src/linklist_fct.cpp
index 4b4736ea53..2977f5fedd 100644
--- a/plugins/HistoryLinkListPlus/src/linklist_fct.cpp
+++ b/plugins/HistoryLinkListPlus/src/linklist_fct.cpp
@@ -57,7 +57,7 @@ int ExtractURI(DBEVENTINFO *dbei, MEVENT hEvent, LISTELEMENT *listStart)
date[0] = 0;
time[0] = 0;
- msg = DbEvent_GetTextW(dbei, CP_ACP);
+ msg = DbEvent_GetTextW(dbei);
if (msg == nullptr)
return 0;
@@ -382,7 +382,7 @@ void WriteLinkList(HWND hDlg, uint8_t params, LISTELEMENT *listStart, LPCTSTR se
{
DB::EventInfo dbe(actualElement->hEvent);
- ptrW msg(DbEvent_GetTextW(&dbe, CP_ACP));
+ ptrW msg(DbEvent_GetTextW(&dbe));
if (wcsstr(msg, searchString))
filter3 = 1;
}
@@ -611,7 +611,7 @@ void WriteMessage(HWND hDlg, LISTELEMENT *listStart, int actLinePos)
SetDlgItemTextW(hDlg, IDC_MESSAGE, L"");
DB::EventInfo dbe(hEvent);
- SendDlgItemMessage(hDlg, IDC_MESSAGE, EM_REPLACESEL, FALSE, ptrW(DbEvent_GetTextW(&dbe, CP_ACP)));
+ SendDlgItemMessage(hDlg, IDC_MESSAGE, EM_REPLACESEL, FALSE, ptrW(DbEvent_GetTextW(&dbe)));
}
break;
}
diff --git a/plugins/HistoryPlusPlus/hpp_events.pas b/plugins/HistoryPlusPlus/hpp_events.pas
index 004095c98f..6f70f39a35 100644
--- a/plugins/HistoryPlusPlus/hpp_events.pas
+++ b/plugins/HistoryPlusPlus/hpp_events.pas
@@ -525,7 +525,7 @@ begin
Result := False;
msg := nil;
try
- msg := DbEvent_GetTextW(@EventInfo, CP_ACP);
+ msg := DbEvent_GetTextW(@EventInfo);
Result := Assigned(msg);
except
if Assigned(msg) then mir_free(msg);
diff --git a/plugins/IEHistory/src/utils.cpp b/plugins/IEHistory/src/utils.cpp
index c9e2e2a5a7..a16465d843 100644
--- a/plugins/IEHistory/src/utils.cpp
+++ b/plugins/IEHistory/src/utils.cpp
@@ -141,7 +141,7 @@ SearchResult SearchHistory(MCONTACT contact, MEVENT hFirstEvent, void *searchDat
switch (type) {
case SEARCH_TEXT:
{
- ptrW data(DbEvent_GetTextW(&dbEvent, CP_UTF8));
+ ptrW data(DbEvent_GetTextW(&dbEvent));
wchar_t *tmp = wcsstr(data, (wchar_t *)searchData);
if (tmp)
found = true;
diff --git a/plugins/IEView/src/HTMLBuilder.cpp b/plugins/IEView/src/HTMLBuilder.cpp
index 3c251572c4..47525671a0 100644
--- a/plugins/IEView/src/HTMLBuilder.cpp
+++ b/plugins/IEView/src/HTMLBuilder.cpp
@@ -229,14 +229,14 @@ void HTMLBuilder::appendEventOld(IEView *view, IEVIEWEVENT *event)
eventData->bIsMe = FALSE;
}
if (dbei.eventType == EVENTTYPE_MESSAGE || dbei.isSrmm()) {
- eventData->szText.w = DbEvent_GetTextW(&dbei, newEvent.codepage);
+ eventData->szText.w = DbEvent_GetTextW(&dbei);
if (dbei.eventType == EVENTTYPE_MESSAGE)
eventData->iType = IEED_EVENT_MESSAGE;
else
eventData->iType = IEED_EVENT_STATUSCHANGE;
}
else if (dbei.eventType == EVENTTYPE_FILE) {
- eventData->szText.w = DbEvent_GetTextW(&dbei, newEvent.codepage);
+ eventData->szText.w = DbEvent_GetTextW(&dbei);
eventData->iType = IEED_EVENT_FILE;
}
else if (dbei.eventType == EVENTTYPE_AUTHREQUEST) {
@@ -252,7 +252,7 @@ void HTMLBuilder::appendEventOld(IEView *view, IEVIEWEVENT *event)
eventData->iType = IEED_EVENT_SYSTEM;
}
else { // custom event
- eventData->szText.w = DbEvent_GetTextW(&dbei, newEvent.codepage);
+ eventData->szText.w = DbEvent_GetTextW(&dbei);
eventData->iType = IEED_EVENT_MESSAGE;
}
diff --git a/plugins/Msg_Export/src/utils.cpp b/plugins/Msg_Export/src/utils.cpp
index 924d26fa58..b4a48cac06 100644
--- a/plugins/Msg_Export/src/utils.cpp
+++ b/plugins/Msg_Export/src/utils.cpp
@@ -789,7 +789,7 @@ static bool ExportDBEventInfo(MCONTACT hContact, HANDLE hFile, const wstring &sF
}
}
else {
- ptrW msg(DbEvent_GetTextW(&dbei, CP_ACP));
+ ptrW msg(DbEvent_GetTextW(&dbei));
if (msg)
pRoot.push_back(JSONNode("body", T2Utf(msg).get()));
}
@@ -820,7 +820,7 @@ static bool ExportDBEventInfo(MCONTACT hContact, HANDLE hFile, const wstring &sF
switch (dbei.eventType) {
case EVENTTYPE_MESSAGE:
- bWriteIndentedToFile(hFile, nIndent, ptrW(DbEvent_GetTextW(&dbei, CP_ACP)), bWriteUTF8Format);
+ bWriteIndentedToFile(hFile, nIndent, ptrW(DbEvent_GetTextW(&dbei)), bWriteUTF8Format);
break;
case EVENTTYPE_FILE:
diff --git a/plugins/NewEventNotify/src/popup.cpp b/plugins/NewEventNotify/src/popup.cpp
index 0c3a43d50c..4fb80b8342 100644
--- a/plugins/NewEventNotify/src/popup.cpp
+++ b/plugins/NewEventNotify/src/popup.cpp
@@ -157,7 +157,7 @@ static wchar_t* ShortenPreview(DB::EventInfo &dbei)
if (iPreviewLimit > 500 || iPreviewLimit == 0)
iPreviewLimit = 500;
- wchar_t *buf = DbEvent_GetTextW(&dbei, CP_ACP);
+ wchar_t *buf = DbEvent_GetTextW(&dbei);
if (mir_wstrlen(buf) > iPreviewLimit) {
fAddEllipsis = true;
size_t iIndex = iPreviewLimit;
@@ -294,7 +294,7 @@ static wchar_t* GetEventPreview(DB::EventInfo &dbei)
// support for custom database event types
DBEVENTTYPEDESCR *pei = DbEvent_GetType(dbei.szModule, dbei.eventType);
if (pei && pBlob) {
- comment1 = DbEvent_GetTextW(&dbei, CP_ACP);
+ comment1 = DbEvent_GetTextW(&dbei);
commentFix = pei->descr;
}
else commentFix = POPUP_COMMENT_OTHER;
diff --git a/plugins/NewStory/src/history_array.cpp b/plugins/NewStory/src/history_array.cpp
index 1193f56449..2d109c1540 100644
--- a/plugins/NewStory/src/history_array.cpp
+++ b/plugins/NewStory/src/history_array.cpp
@@ -61,7 +61,7 @@ bool Filter::check(ItemData *item) const
if (!item->fetch())
return false;
- return CheckFilter(ptrW(DbEvent_GetTextW(&item->dbe, CP_UTF8)), text);
+ return CheckFilter(ptrW(DbEvent_GetTextW(&item->dbe)), text);
}
return true;
@@ -441,7 +441,7 @@ void ItemData::load(bool bLoadAlways)
break;
default:
- wtext = DbEvent_GetTextW(&dbe, CP_ACP);
+ wtext = DbEvent_GetTextW(&dbe);
break;
}
@@ -457,7 +457,7 @@ void ItemData::load(bool bLoadAlways)
}
else str.AppendFormat(L"%s %s: ", Clist_GetContactDisplayName(hContact, 0), TranslateT("wrote"));
- ptrW wszText(DbEvent_GetTextW(&dbei, CP_ACP));
+ ptrW wszText(DbEvent_GetTextW(&dbei));
if (mir_wstrlen(wszText) > 43)
wcscpy(wszText.get() + 40, L"...");
str.Append(wszText);
diff --git a/plugins/NewStory/src/history_dlg.cpp b/plugins/NewStory/src/history_dlg.cpp
index c012b9651f..e4f966e852 100644
--- a/plugins/NewStory/src/history_dlg.cpp
+++ b/plugins/NewStory/src/history_dlg.cpp
@@ -174,7 +174,7 @@ class CHistoryDlg : public CDlgBase
if (!dbei)
continue;
- ptrW pwszText(DbEvent_GetTextW(&dbei, CP_UTF8));
+ ptrW pwszText(DbEvent_GetTextW(&dbei));
if (!mir_wstrlen(pwszText))
continue;
@@ -215,7 +215,7 @@ class CHistoryDlg : public CDlgBase
flags += "r";
pRoot2.push_back(JSONNode("flags", flags));
- ptrW msg(DbEvent_GetTextW(&dbei, CP_ACP));
+ ptrW msg(DbEvent_GetTextW(&dbei));
if (msg)
pRoot2.push_back(JSONNode("body", T2Utf(msg).get()));
diff --git a/plugins/Scriver/src/msgdialog.cpp b/plugins/Scriver/src/msgdialog.cpp
index c4b69baf9e..0ab0d77f11 100644
--- a/plugins/Scriver/src/msgdialog.cpp
+++ b/plugins/Scriver/src/msgdialog.cpp
@@ -382,7 +382,7 @@ void CMsgDialog::onClick_Quote(CCtrlButton*)
return;
if (DbEventIsMessageOrCustom(dbei)) {
- ptrW wszText(DbEvent_GetTextW(&dbei, CP_ACP));
+ ptrW wszText(DbEvent_GetTextW(&dbei));
SetMessageText(Srmm_Quote(wszText));
}
}
diff --git a/plugins/Scriver/src/msglog.cpp b/plugins/Scriver/src/msglog.cpp
index 0f5867f734..cf68b2a7cc 100644
--- a/plugins/Scriver/src/msglog.cpp
+++ b/plugins/Scriver/src/msglog.cpp
@@ -398,7 +398,7 @@ public:
}
bool bIsRtl = (dbei.flags & DBEF_RTL) != 0;
- ptrW wszText(DbEvent_GetTextW(&dbei, CP_UTF8)), wszNick;
+ ptrW wszText(DbEvent_GetTextW(&dbei)), wszNick;
// test contact
if (streamData->dbei == 0) {
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp
index 7db8739e27..90170af3b1 100644
--- a/plugins/TabSRMM/src/msgdialog.cpp
+++ b/plugins/TabSRMM/src/msgdialog.cpp
@@ -934,7 +934,7 @@ void CMsgDialog::onClick_Quote(CCtrlButton*)
if (szQuoted.IsEmpty()) {
DB::EventInfo dbei(hDBEvent);
if (dbei)
- szQuoted = Srmm_Quote(ptrW(DbEvent_GetTextW(&dbei, CP_ACP)), iOutputWidth);
+ szQuoted = Srmm_Quote(ptrW(DbEvent_GetTextW(&dbei)), iOutputWidth);
}
}
diff --git a/plugins/TabSRMM/src/msglog.cpp b/plugins/TabSRMM/src/msglog.cpp
index 2ae3bd5186..18759fbbdf 100644
--- a/plugins/TabSRMM/src/msglog.cpp
+++ b/plugins/TabSRMM/src/msglog.cpp
@@ -573,7 +573,7 @@ bool CLogWindow::CreateRtfEvent(RtfLogStreamData *streamData, DB::EventInfo &dbe
if (!isSent && bIsStatusChangeEvent)
dbei.wipeNotify(streamData->hDbEvent);
- CMStringW msg(ptrW(DbEvent_GetTextW(&dbei, CP_UTF8)));
+ CMStringW msg(ptrW(DbEvent_GetTextW(&dbei)));
if (msg.IsEmpty())
return nullptr;
@@ -981,7 +981,7 @@ bool CLogWindow::CreateRtfEvent(RtfLogStreamData *streamData, DB::EventInfo &dbe
if (blob.isOffline())
InsertFileLink(str, streamData->hDbEvent, blob);
else
- AppendUnicodeToBuffer(str, ptrW(DbEvent_GetTextW(&dbei, CP_ACP)), 0);
+ AppendUnicodeToBuffer(str, ptrW(DbEvent_GetTextW(&dbei)), 0);
}
break;
@@ -991,7 +991,7 @@ bool CLogWindow::CreateRtfEvent(RtfLogStreamData *streamData, DB::EventInfo &dbe
str.AppendChar(' ');
}
- ptrW tszText(DbEvent_GetTextW(&dbei, CP_ACP));
+ ptrW tszText(DbEvent_GetTextW(&dbei));
AppendUnicodeToBuffer(str, tszText, 0);
}
break;
diff --git a/plugins/TipperYM/src/subst.cpp b/plugins/TipperYM/src/subst.cpp
index a7aafa717d..34ab44cceb 100644
--- a/plugins/TipperYM/src/subst.cpp
+++ b/plugins/TipperYM/src/subst.cpp
@@ -173,7 +173,7 @@ wchar_t* GetLastMessageText(MCONTACT hContact, bool received)
if (dbei.cbBlob == 0 || dbei.pBlob == nullptr)
return nullptr;
- wchar_t *buff = DbEvent_GetTextW(&dbei, CP_ACP);
+ wchar_t *buff = DbEvent_GetTextW(&dbei);
wchar_t *swzMsg = mir_wstrdup(buff);
mir_free(buff);
diff --git a/plugins/Variables/src/parse_miranda.cpp b/plugins/Variables/src/parse_miranda.cpp
index 8996cbbc46..1a754bc4d8 100644
--- a/plugins/Variables/src/parse_miranda.cpp
+++ b/plugins/Variables/src/parse_miranda.cpp
@@ -565,7 +565,7 @@ static wchar_t* parseDbEvent(ARGUMENTSINFO *ai)
return nullptr;
DB::EventInfo dbe(hDbEvent);
- return (dbe) ? DbEvent_GetTextW(&dbe, CP_ACP) : nullptr;
+ return (dbe) ? DbEvent_GetTextW(&dbe) : nullptr;
}
static wchar_t* parseTranslate(ARGUMENTSINFO *ai)
diff --git a/plugins/wbOSD/src/events.cpp b/plugins/wbOSD/src/events.cpp
index f456b4aab1..a408f69655 100644
--- a/plugins/wbOSD/src/events.cpp
+++ b/plugins/wbOSD/src/events.cpp
@@ -181,12 +181,12 @@ int HookedNewEvent(WPARAM wParam, LPARAM hDBEvent)
if (i1 == 1)
c1 = mir_wstrdup(Clist_GetContactDisplayName(wParam));
else if (i1 == 2)
- c1 = DbEvent_GetTextW(&dbe, 0);
+ c1 = DbEvent_GetTextW(&dbe);
if (i2 == 1)
c2 = mir_wstrdup(Clist_GetContactDisplayName(wParam));
else if (i2 == 2)
- c2 = DbEvent_GetTextW(&dbe, 0);
+ c2 = DbEvent_GetTextW(&dbe);
wchar_t buffer[512];
mir_snwprintf(buffer, buf, c1, c2);