summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/TabSRMM/src')
-rw-r--r--plugins/TabSRMM/src/buttonsbar.cpp2
-rw-r--r--plugins/TabSRMM/src/chat/main.cpp2
-rw-r--r--plugins/TabSRMM/src/eventpopups.cpp8
-rw-r--r--plugins/TabSRMM/src/msglog.cpp10
-rw-r--r--plugins/TabSRMM/src/srmm.cpp2
5 files changed, 12 insertions, 12 deletions
diff --git a/plugins/TabSRMM/src/buttonsbar.cpp b/plugins/TabSRMM/src/buttonsbar.cpp
index f85ad9bed1..36124651a1 100644
--- a/plugins/TabSRMM/src/buttonsbar.cpp
+++ b/plugins/TabSRMM/src/buttonsbar.cpp
@@ -611,7 +611,7 @@ INT_PTR CALLBACK DlgProcToolBar(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l
switch (LOWORD(wParam)) {
case IDC_BBRESET:
- CallService(MS_DB_MODULE_DELETE, NULL, LPARAM("TabSRMM_Toolbar"));
+ DbModule_Delete(NULL, "TabSRMM_Toolbar");
CB_HardReInit();
BuildMenuObjectsTree(hToolBarTree);
break;
diff --git a/plugins/TabSRMM/src/chat/main.cpp b/plugins/TabSRMM/src/chat/main.cpp
index 0694e9f815..aa1d32a4fd 100644
--- a/plugins/TabSRMM/src/chat/main.cpp
+++ b/plugins/TabSRMM/src/chat/main.cpp
@@ -242,7 +242,7 @@ static void CheckUpdate()
mir_free(p);
}
- CallService(MS_DB_MODULE_DELETE, 0, (LPARAM)CHAT_OLDFONTMODULE);
+ DbModule_Delete(NULL, CHAT_OLDFONTMODULE);
compat++;
}
diff --git a/plugins/TabSRMM/src/eventpopups.cpp b/plugins/TabSRMM/src/eventpopups.cpp
index 9c552aaaa9..ed7cc7618a 100644
--- a/plugins/TabSRMM/src/eventpopups.cpp
+++ b/plugins/TabSRMM/src/eventpopups.cpp
@@ -421,7 +421,7 @@ static wchar_t* ShortenPreview(DBEVENTINFO* dbe)
if (iPreviewLimit > 500 || iPreviewLimit == 0)
iPreviewLimit = 500;
- wchar_t *buf = DbGetEventTextW(dbe, CP_ACP);
+ wchar_t *buf = DbEvent_GetTextW(dbe, CP_ACP);
if (mir_wstrlen(buf) > iPreviewLimit) {
fAddEllipsis = true;
size_t iIndex = iPreviewLimit;
@@ -462,11 +462,11 @@ static wchar_t* GetPreviewT(WORD eventType, DBEVENTINFO* dbe)
if (dbe->cbBlob > (sizeof(DWORD) + namelength + 1))
szDescr = szFileName + namelength + 1;
- ptrW tszFileName(DbGetEventStringT(dbe, szFileName));
+ ptrW tszFileName(DbEvent_GetString(dbe, szFileName));
wchar_t buf[1024];
if (szDescr && Utils::safe_strlen(szDescr, dbe->cbBlob - sizeof(DWORD) - namelength - 1) > 0) {
- ptrW tszDescr(DbGetEventStringT(dbe, szDescr));
+ ptrW tszDescr(DbEvent_GetString(dbe, szDescr));
if (tszFileName && tszDescr) {
mir_snwprintf(buf, L"%s: %s (%s)", TranslateT("Incoming file"), tszFileName, tszDescr);
return mir_wstrdup(buf);
@@ -591,7 +591,7 @@ static int PopupShowT(NEN_OPTIONS *pluginOptions, MCONTACT hContact, MEVENT hEve
break;
default:
- pud.lchIcon = (HICON)CallService(MS_DB_EVENT_GETICON, LR_SHARED, (LPARAM)&dbe);
+ pud.lchIcon = DbEvent_GetIcon(&dbe, LR_SHARED);
pud.colorBack = pluginOptions->bDefaultColorOthers ? 0 : pluginOptions->colBackOthers;
pud.colorText = pluginOptions->bDefaultColorOthers ? 0 : pluginOptions->colTextOthers;
iSeconds = pluginOptions->iDelayOthers;
diff --git a/plugins/TabSRMM/src/msglog.cpp b/plugins/TabSRMM/src/msglog.cpp
index 6f0a78a476..eda978011e 100644
--- a/plugins/TabSRMM/src/msglog.cpp
+++ b/plugins/TabSRMM/src/msglog.cpp
@@ -387,7 +387,7 @@ int TSAPI DbEventIsShown(DBEVENTINFO *dbei)
int DbEventIsForMsgWindow(DBEVENTINFO *dbei)
{
- DBEVENTTYPEDESCR *et = (DBEVENTTYPEDESCR*)CallService(MS_DB_EVENT_GETTYPE, (WPARAM)dbei->szModule, (LPARAM)dbei->eventType);
+ DBEVENTTYPEDESCR *et = DbEvent_GetType(dbei->szModule, dbei->eventType);
return et && (et->flags & DETF_MSGWINDOW);
}
@@ -420,7 +420,7 @@ static char* Template_CreateRTFFromDbEvent(TWindowData *dat, MCONTACT hContact,
dat->cache->updateStats(TSessionStats::SET_LAST_RCV, mir_strlen((char *)dbei.pBlob));
wchar_t *formatted = NULL;
- wchar_t *msg = DbGetEventTextW(&dbei, CP_UTF8);
+ wchar_t *msg = DbEvent_GetTextW(&dbei, CP_UTF8);
if (!msg) {
mir_free(dbei.pBlob);
return NULL;
@@ -824,11 +824,11 @@ static char* Template_CreateRTFFromDbEvent(TWindowData *dat, MCONTACT hContact,
}
{
char *szFileName = (char *)dbei.pBlob + sizeof(DWORD);
- ptrW tszFileName(DbGetEventStringT(&dbei, szFileName));
+ ptrW tszFileName(DbEvent_GetString(&dbei, szFileName));
char *szDescr = szFileName + mir_strlen(szFileName) + 1;
if (*szDescr != 0) {
- ptrW tszDescr(DbGetEventStringT(&dbei, szDescr));
+ ptrW tszDescr(DbEvent_GetString(&dbei, szDescr));
wchar_t buf[1000];
mir_snwprintf(buf, L"%s (%s)", tszFileName, tszDescr);
@@ -844,7 +844,7 @@ static char* Template_CreateRTFFromDbEvent(TWindowData *dat, MCONTACT hContact,
str.AppendChar(' ');
}
- ptrW tszText(DbGetEventTextW(&dbei, CP_ACP));
+ ptrW tszText(DbEvent_GetTextW(&dbei, CP_ACP));
AppendUnicodeToBuffer(str, tszText, 0);
}
break;
diff --git a/plugins/TabSRMM/src/srmm.cpp b/plugins/TabSRMM/src/srmm.cpp
index 750f006ed3..d744568995 100644
--- a/plugins/TabSRMM/src/srmm.cpp
+++ b/plugins/TabSRMM/src/srmm.cpp
@@ -119,7 +119,7 @@ int _DebugTraceW(const wchar_t *fmt, ...)
char szLogFileName[MAX_PATH], szDataPath[MAX_PATH];
FILE *f;
- CallService(MS_DB_GETPROFILEPATH, MAX_PATH, (LPARAM)szDataPath);
+ Profile_GetPathA(MAX_PATH, szDataPath);
mir_snprintf(szLogFileName, "%s\\%s", szDataPath, "tabsrmm_debug.log");
f = fopen(szLogFileName, "a+");
if (f) {