summaryrefslogtreecommitdiff
path: root/src/modules/srawaymsg
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-06-26 16:50:14 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-06-26 16:50:14 +0000
commitc992cb2fdc11f1cac4bc5cbce26e8e2bb3b57da0 (patch)
tree697bdbf38a8a1f6b828a8bfbd08a478e19a82c6b /src/modules/srawaymsg
parentf616294363c642d138f9dc0ef6eceae639e2434c (diff)
- microkernel addded;
- version bumped to 0.92.2 git-svn-id: http://svn.miranda-ng.org/main/trunk@641 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/modules/srawaymsg')
-rw-r--r--src/modules/srawaymsg/awaymsg.cpp6
-rw-r--r--src/modules/srawaymsg/sendmsg.cpp20
2 files changed, 13 insertions, 13 deletions
diff --git a/src/modules/srawaymsg/awaymsg.cpp b/src/modules/srawaymsg/awaymsg.cpp
index e480dab74a..82ea8f2121 100644
--- a/src/modules/srawaymsg/awaymsg.cpp
+++ b/src/modules/srawaymsg/awaymsg.cpp
@@ -125,7 +125,7 @@ static INT_PTR GetMessageCommand(WPARAM wParam, LPARAM)
SetForegroundWindow(hwnd);
SetFocus(hwnd);
}
- else CreateDialogParam(hMirandaInst, MAKEINTRESOURCE(IDD_READAWAYMSG), NULL, ReadAwayMsgDlgProc, wParam);
+ else CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_READAWAYMSG), NULL, ReadAwayMsgDlgProc, wParam);
return 0;
}
@@ -146,8 +146,8 @@ static int AwayMsgPreBuildMenu(WPARAM wParam, LPARAM)
int status = DBGetContactSettingWord((HANDLE)wParam, szProto, "Status", ID_STATUS_OFFLINE);
mir_sntprintf(str, SIZEOF(str), TranslateT("Re&ad %s Message"), cli.pfnGetStatusModeDescription(status, 0));
clmi.ptszName = str;
- if (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGRECV) {
- if (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(status)) {
+ if (CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGRECV) {
+ if (CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(status)) {
clmi.flags = CMIM_FLAGS | CMIM_NAME | CMIF_NOTOFFLINE | CMIM_ICON | CMIF_TCHAR;
clmi.hIcon = LoadSkinProtoIcon(szProto, status);
} } } }
diff --git a/src/modules/srawaymsg/sendmsg.cpp b/src/modules/srawaymsg/sendmsg.cpp
index d11f80715a..843b43f64f 100644
--- a/src/modules/srawaymsg/sendmsg.cpp
+++ b/src/modules/srawaymsg/sendmsg.cpp
@@ -73,7 +73,7 @@ static TCHAR* GetAwayMessage(int statusMode, char *szProto)
{
DBVARIANT dbv;
- if (szProto && !(CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
+ if (szProto && !(CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
return NULL;
if (DBGetContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Ignore"), 0))
@@ -176,13 +176,13 @@ void ChangeAllProtoMessages(char *szProto, int statusMode, TCHAR *msg)
{
PROTOACCOUNT* pa = accounts[i];
if ( !Proto_IsAccountEnabled(pa)) continue;
- if ((CallProtoService(pa->szModuleName, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) &&
+ if ((CallProtoServiceInt(NULL,pa->szModuleName, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) &&
!Proto_IsAccountLocked(pa))
- CallProtoService(pa->szModuleName, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
+ CallProtoServiceInt(NULL,pa->szModuleName, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
}
}
else
- CallProtoService(szProto, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
+ CallProtoServiceInt(NULL,szProto, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
}
struct SetAwayMsgData
@@ -323,8 +323,8 @@ static int StatusModeChange(WPARAM wParam, LPARAM lParam)
else
{
// If its a single protocol check the PFLAGNUM_3 for the single protocol
- if ( !(CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) ||
- !(CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
+ if ( !(CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) ||
+ !(CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
return 0;
}
@@ -346,7 +346,7 @@ static int StatusModeChange(WPARAM wParam, LPARAM lParam)
newdat->statusMode = statusMode;
if (hwndStatusMsg)
DestroyWindow(hwndStatusMsg);
- hwndStatusMsg = CreateDialogParam(hMirandaInst, MAKEINTRESOURCE(IDD_SETAWAYMSG),
+ hwndStatusMsg = CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_SETAWAYMSG),
NULL, SetAwayMsgDlgProc, (LPARAM)newdat);
}
return 0;
@@ -547,7 +547,7 @@ static int AwayMsgOptInitialise(WPARAM wParam, LPARAM)
OPTIONSDIALOGPAGE odp = { 0 };
odp.cbSize = sizeof(odp);
odp.position = 870000000;
- odp.hInstance = hMirandaInst;
+ odp.hInstance = hInst;
odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPT_AWAYMSG);
odp.pszTitle = LPGEN("Status Messages");
odp.pszGroup = LPGEN("Status");
@@ -570,7 +570,7 @@ static int AwayMsgSendModernOptInit(WPARAM wParam, LPARAM)
MODERNOPTOBJECT obj = {0};
obj.cbSize = sizeof(obj);
- obj.hInstance = hMirandaInst;
+ obj.hInstance = hInst;
obj.dwFlags = MODEROPT_FLG_TCHAR | MODEROPT_FLG_NORESIZE;
obj.iSection = MODERNOPT_PAGE_STATUS;
obj.iType = MODERNOPT_TYPE_SECTIONPAGE;
@@ -590,7 +590,7 @@ static int AwayMsgSendAccountsChanged(WPARAM, LPARAM)
for (int i=0; i < accounts.getCount(); i++)
{
if ( !Proto_IsAccountEnabled(accounts[i])) continue;
- protoModeMsgFlags |= CallProtoService(accounts[i]->szModuleName, PS_GETCAPS, PFLAGNUM_3, 0);
+ protoModeMsgFlags |= CallProtoServiceInt(NULL,accounts[i]->szModuleName, PS_GETCAPS, PFLAGNUM_3, 0);
}
return 0;