summaryrefslogtreecommitdiff
path: root/plugins/IEView/src/TabSRMMHTMLBuilder.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/IEView/src/TabSRMMHTMLBuilder.cpp')
-rw-r--r--plugins/IEView/src/TabSRMMHTMLBuilder.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/plugins/IEView/src/TabSRMMHTMLBuilder.cpp b/plugins/IEView/src/TabSRMMHTMLBuilder.cpp
index f407dd62b4..23a2706b57 100644
--- a/plugins/IEView/src/TabSRMMHTMLBuilder.cpp
+++ b/plugins/IEView/src/TabSRMMHTMLBuilder.cpp
@@ -105,8 +105,8 @@ bool TabSRMMHTMLBuilder::isDbEventShown(DWORD dwFlags, DBEVENTINFO * dbei)
bool TabSRMMHTMLBuilder::isDbEventShown(DBEVENTINFO * dbei)
{
- DWORD dwFlags2 = DBGetContactSettingByte(NULL, SRMSGMOD_T, SRMSGSET_SHOWURLS, 0) ? MWF_SHOW_URLEVENTS : 0;
- dwFlags2 |= DBGetContactSettingByte(NULL, SRMSGMOD_T, SRMSGSET_SHOWFILES, 0) ? MWF_SHOW_FILEEVENTS : 0;
+ DWORD dwFlags2 = db_get_b(NULL, SRMSGMOD_T, SRMSGSET_SHOWURLS, 0) ? MWF_SHOW_URLEVENTS : 0;
+ dwFlags2 |= db_get_b(NULL, SRMSGMOD_T, SRMSGSET_SHOWFILES, 0) ? MWF_SHOW_FILEEVENTS : 0;
return isDbEventShown(dwFlags2, dbei);
}
@@ -116,7 +116,7 @@ void TabSRMMHTMLBuilder::loadMsgDlgFont(int i, LOGFONTA * lf, COLORREF * colour)
DBVARIANT dbv;
if (colour) {
wsprintfA(str, "Font%dCol", i);
- *colour = DBGetContactSettingDword(NULL, TABSRMM_FONTMODULE, str, 0x000000);
+ *colour = db_get_dw(NULL, TABSRMM_FONTMODULE, str, 0x000000);
}
if (lf) {
HDC hdc = GetDC(NULL);
@@ -124,7 +124,7 @@ void TabSRMMHTMLBuilder::loadMsgDlgFont(int i, LOGFONTA * lf, COLORREF * colour)
// if(i == H_MSGFONTID_DIVIDERS)
// lf->lfHeight = 5;
// else {
- lf->lfHeight = (char) DBGetContactSettingByte(NULL, TABSRMM_FONTMODULE, str, 10);
+ lf->lfHeight = (char) db_get_b(NULL, TABSRMM_FONTMODULE, str, 10);
// lf->lfHeight= MulDiv(lf->lfHeight, GetDeviceCaps(hdc, LOGPIXELSY), 74);
// }
ReleaseDC(NULL,hdc);
@@ -132,23 +132,23 @@ void TabSRMMHTMLBuilder::loadMsgDlgFont(int i, LOGFONTA * lf, COLORREF * colour)
lf->lfEscapement = 0;
lf->lfOrientation = 0;
wsprintfA(str, "Font%dSty", i);
- style = DBGetContactSettingByte(NULL, TABSRMM_FONTMODULE, str, 0);
+ style = db_get_b(NULL, TABSRMM_FONTMODULE, str, 0);
lf->lfWeight = style & FONTF_BOLD ? FW_BOLD : FW_NORMAL;
lf->lfItalic = style & FONTF_ITALIC ? 1 : 0;
lf->lfUnderline = style & FONTF_UNDERLINE ? 1 : 0;
lf->lfStrikeOut = 0;
wsprintfA(str, "Font%dSet", i);
- lf->lfCharSet = DBGetContactSettingByte(NULL, TABSRMM_FONTMODULE, str, DEFAULT_CHARSET);
+ lf->lfCharSet = db_get_b(NULL, TABSRMM_FONTMODULE, str, DEFAULT_CHARSET);
lf->lfOutPrecision = OUT_DEFAULT_PRECIS;
lf->lfClipPrecision = CLIP_DEFAULT_PRECIS;
lf->lfQuality = DEFAULT_QUALITY;
lf->lfPitchAndFamily = DEFAULT_PITCH | FF_DONTCARE;
wsprintfA(str, "Font%d", i);
- if (DBGetContactSetting(NULL, TABSRMM_FONTMODULE, str, &dbv))
+ if (db_get(NULL, TABSRMM_FONTMODULE, str, &dbv))
lstrcpyA(lf->lfFaceName, "Verdana");
else {
lstrcpynA(lf->lfFaceName, dbv.pszVal, sizeof(lf->lfFaceName));
- DBFreeVariant(&dbv);
+ db_free(&dbv);
}
}
}
@@ -229,16 +229,16 @@ void TabSRMMHTMLBuilder::buildHead(IEView *view, IEVIEWEVENT *event) {
HDC hdc = GetDC(NULL);
int logPixelSY = GetDeviceCaps(hdc, LOGPIXELSY);
ReleaseDC(NULL, hdc);
- DWORD dwFlags = DBGetContactSettingDword(NULL, SRMSGMOD_T, "mwflags", MWF_LOG_DEFAULT);
+ DWORD dwFlags = db_get_dw(NULL, SRMSGMOD_T, "mwflags", MWF_LOG_DEFAULT);
Utils::appendText(&output, &outputSize, "<html><head><style type=\"text/css\">\n");
COLORREF inColor, outColor;
- COLORREF bkgColor = DBGetContactSettingDword(NULL, TABSRMM_FONTMODULE, "BkgColour", 0xFFFFFF);
+ COLORREF bkgColor = db_get_dw(NULL, TABSRMM_FONTMODULE, "BkgColour", 0xFFFFFF);
bkgColor= (((bkgColor & 0xFF) << 16) | (bkgColor & 0xFF00) | ((bkgColor & 0xFF0000) >> 16));
- COLORREF gridColor = DBGetContactSettingDword(NULL, TABSRMM_FONTMODULE, "hgrid", 0xFFFFFF);
+ COLORREF gridColor = db_get_dw(NULL, TABSRMM_FONTMODULE, "hgrid", 0xFFFFFF);
gridColor= (((gridColor & 0xFF) << 16) | (gridColor & 0xFF00) | ((gridColor & 0xFF0000) >> 16));
if (dwFlags & MWF_LOG_INDIVIDUALBKG) {
- inColor = DBGetContactSettingDword(NULL, TABSRMM_FONTMODULE, "inbg", RGB(224,224,224));
- outColor = DBGetContactSettingDword(NULL, TABSRMM_FONTMODULE, "outbg", RGB(224,224,224));
+ inColor = db_get_dw(NULL, TABSRMM_FONTMODULE, "inbg", RGB(224,224,224));
+ outColor = db_get_dw(NULL, TABSRMM_FONTMODULE, "outbg", RGB(224,224,224));
inColor= (((inColor & 0xFF) << 16) | (inColor & 0xFF00) | ((inColor & 0xFF0000) >> 16));
outColor= (((outColor & 0xFF) << 16) | (outColor & 0xFF00) | ((outColor & 0xFF0000) >> 16));
} else {
@@ -300,17 +300,17 @@ time_t TabSRMMHTMLBuilder::getStartedTime() {
}
void TabSRMMHTMLBuilder::appendEventNonTemplate(IEView *view, IEVIEWEVENT *event) {
-// int indentLeft = DBGetContactSettingDword(NULL, SRMSGMOD_T, "IndentAmount", 0);
-// int indentRight = DBGetContactSettingDword(NULL, SRMSGMOD_T, "RightIndent", 0);
+// int indentLeft = db_get_dw(NULL, SRMSGMOD_T, "IndentAmount", 0);
+// int indentRight = db_get_dw(NULL, SRMSGMOD_T, "RightIndent", 0);
DWORD today = (DWORD)time(NULL);
today = today - today % 86400;
- DWORD dwFlags = DBGetContactSettingDword(NULL, SRMSGMOD_T, "mwflags", MWF_LOG_DEFAULT);
- DWORD dwFlags2 = DBGetContactSettingByte(NULL, SRMSGMOD_T, SRMSGSET_SHOWURLS, 0) ? MWF_SHOW_URLEVENTS : 0;
- dwFlags2 |= DBGetContactSettingByte(NULL, SRMSGMOD_T, SRMSGSET_SHOWFILES, 0) ? MWF_SHOW_FILEEVENTS : 0;
- dwFlags2 |= DBGetContactSettingByte(NULL, SRMSGMOD_T, "in_out_icons", 0) ? MWF_SHOW_INOUTICONS : 0;
- dwFlags2 |= DBGetContactSettingByte(NULL, SRMSGMOD_T, "emptylinefix", 1) ? MWF_SHOW_EMPTYLINEFIX : 0;
+ DWORD dwFlags = db_get_dw(NULL, SRMSGMOD_T, "mwflags", MWF_LOG_DEFAULT);
+ DWORD dwFlags2 = db_get_b(NULL, SRMSGMOD_T, SRMSGSET_SHOWURLS, 0) ? MWF_SHOW_URLEVENTS : 0;
+ dwFlags2 |= db_get_b(NULL, SRMSGMOD_T, SRMSGSET_SHOWFILES, 0) ? MWF_SHOW_FILEEVENTS : 0;
+ dwFlags2 |= db_get_b(NULL, SRMSGMOD_T, "in_out_icons", 0) ? MWF_SHOW_INOUTICONS : 0;
+ dwFlags2 |= db_get_b(NULL, SRMSGMOD_T, "emptylinefix", 1) ? MWF_SHOW_EMPTYLINEFIX : 0;
dwFlags2 |= MWF_SHOW_MICROLF;
- dwFlags2 |= DBGetContactSettingByte(NULL, SRMSGMOD_T, "followupts", 1) ? MWF_SHOW_MARKFOLLOWUPTS : 0;
+ dwFlags2 |= db_get_b(NULL, SRMSGMOD_T, "followupts", 1) ? MWF_SHOW_MARKFOLLOWUPTS : 0;
char *szRealProto = getRealProto(event->hContact);
IEVIEWEVENTDATA* eventData = event->eventData;