diff options
Diffstat (limited to 'plugins')
155 files changed, 392 insertions, 392 deletions
diff --git a/plugins/AVS/src/cache.cpp b/plugins/AVS/src/cache.cpp index 56a443afab..472c03e1a2 100644 --- a/plugins/AVS/src/cache.cpp +++ b/plugins/AVS/src/cache.cpp @@ -151,7 +151,7 @@ void NotifyMetaAware(MCONTACT hContact, CacheNode *node = NULL, AVATARCACHEENTRY if (ace == (AVATARCACHEENTRY *)-1)
ace = &node->ace;
- NotifyEventHooks(hEventChanged, (WPARAM)hContact, (LPARAM)ace);
+ NotifyEventHooks(hEventChanged, hContact, (LPARAM)ace);
if (g_MetaAvail && (node->dwFlags & MC_ISSUBCONTACT) && db_get_b(NULL, g_szMetaName, "Enabled", 0)) {
MCONTACT hMasterContact = (MCONTACT)db_get_dw(hContact, g_szMetaName, "Handle", 0);
@@ -192,7 +192,7 @@ void NotifyMetaAware(MCONTACT hContact, CacheNode *node = NULL, AVATARCACHEENTRY NotifyEventHooks(hEventContactAvatarChanged, (WPARAM)cacn.hContact, (LPARAM)&cacn);
}
- else NotifyEventHooks(hEventContactAvatarChanged, (WPARAM)hContact, NULL);
+ else NotifyEventHooks(hEventContactAvatarChanged, hContact, NULL);
}
}
diff --git a/plugins/AVS/src/main.cpp b/plugins/AVS/src/main.cpp index 9b00e6be82..aa6531e167 100644 --- a/plugins/AVS/src/main.cpp +++ b/plugins/AVS/src/main.cpp @@ -144,7 +144,7 @@ static int MetaChanged(WPARAM hContact, LPARAM lParam) }
else ace = &node->ace;
- NotifyEventHooks(hEventChanged, (WPARAM)hContact, (LPARAM)ace);
+ NotifyEventHooks(hEventChanged, hContact, (LPARAM)ace);
return 0;
}
diff --git a/plugins/AVS/src/options.cpp b/plugins/AVS/src/options.cpp index 6d28942e5c..4622f0d1b2 100644 --- a/plugins/AVS/src/options.cpp +++ b/plugins/AVS/src/options.cpp @@ -507,7 +507,7 @@ INT_PTR CALLBACK DlgProcAvatarOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPA hContact = lParam;
TranslateDialogDefault(hwndDlg);
if (hContact) {
- szNick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ szNick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
mir_sntprintf(szTitle, 500, TranslateT("Set avatar options for %s"), szNick);
SetWindowText(hwndDlg, szTitle);
}
@@ -564,12 +564,12 @@ INT_PTR CALLBACK DlgProcAvatarOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPA case IDC_PROTECTAVATAR:
{
BOOL locked = IsDlgButtonChecked(hwndDlg, IDC_PROTECTAVATAR);
- ProtectAvatar((WPARAM)hContact, locked ? 1 : 0);
+ ProtectAvatar(hContact, locked ? 1 : 0);
}
break;
case IDC_CHANGE:
- SetAvatar((WPARAM)hContact, 0);
+ SetAvatar(hContact, 0);
SendMessage(hwndDlg, DM_SETAVATARNAME, 0, 0);
CheckDlgButton(hwndDlg, IDC_PROTECTAVATAR, db_get_b(hContact, "ContactPhoto", "Locked", 0) ? TRUE : FALSE);
break;
@@ -598,7 +598,7 @@ INT_PTR CALLBACK DlgProcAvatarOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPA char *szProto = GetContactProto(hContact);
DBVARIANT dbv = {0};
- ProtectAvatar((WPARAM)hContact, 0);
+ ProtectAvatar(hContact, 0);
if (MessageBox(0, TranslateT("Delete picture file from disk (may be necessary to force a reload, but will delete local pictures)?"), TranslateT("Reset contact picture"), MB_YESNO) == IDYES) {
if ( !db_get_ts(hContact, "ContactPhoto", "File", &dbv)) {
DeleteFile(dbv.ptszVal);
@@ -623,7 +623,7 @@ INT_PTR CALLBACK DlgProcAvatarOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPA case IDC_DELETE:
{
DBVARIANT dbv = {0};
- ProtectAvatar((WPARAM)hContact, 0);
+ ProtectAvatar(hContact, 0);
if (MessageBox(0, TranslateT("Delete picture file from disk (may be necessary to force a reload, but will delete local pictures)?"), TranslateT("Reset contact picture"), MB_YESNO) == IDYES) {
if ( !db_get_ts(hContact, "ContactPhoto", "File", &dbv)) {
DeleteFile(dbv.ptszVal);
@@ -812,7 +812,7 @@ static INT_PTR CALLBACK DlgProcAvatarUserInfo(HWND hwndDlg, UINT msg, WPARAM wPa break;
case IDC_CHANGE:
- SetAvatar((WPARAM)hContact, 0);
+ SetAvatar(hContact, 0);
SendMessage(hwndDlg, DM_SETAVATARNAME, 0, 0);
CheckDlgButton(hwndDlg, IDC_PROTECTAVATAR, db_get_b(hContact, "ContactPhoto", "Locked", 0) ? TRUE : FALSE);
break;
@@ -830,7 +830,7 @@ static INT_PTR CALLBACK DlgProcAvatarUserInfo(HWND hwndDlg, UINT msg, WPARAM wPa {
BOOL locked = IsDlgButtonChecked(hwndDlg, IDC_PROTECTAVATAR);
SaveTransparentData(hwndDlg, hContact, locked);
- ProtectAvatar((WPARAM)hContact, locked ? 1 : 0);
+ ProtectAvatar(hContact, locked ? 1 : 0);
break;
}
@@ -856,7 +856,7 @@ static INT_PTR CALLBACK DlgProcAvatarUserInfo(HWND hwndDlg, UINT msg, WPARAM wPa char *szProto = GetContactProto(hContact);
DBVARIANT dbv = {0};
- ProtectAvatar((WPARAM)hContact, 0);
+ ProtectAvatar(hContact, 0);
if (MessageBox(0, TranslateT("Delete picture file from disk (may be necessary to force a reload, but will delete local pictures)?"), TranslateT("Reset contact picture"), MB_YESNO) == IDYES) {
if ( !db_get_ts(hContact, "ContactPhoto", "File", &dbv)) {
DeleteFile(dbv.ptszVal);
@@ -879,7 +879,7 @@ static INT_PTR CALLBACK DlgProcAvatarUserInfo(HWND hwndDlg, UINT msg, WPARAM wPa {
DBVARIANT dbv = {0};
- ProtectAvatar((WPARAM)hContact, 0);
+ ProtectAvatar(hContact, 0);
if (MessageBox(0, TranslateT("Delete picture file from disk (may be necessary to force a reload, but will delete local pictures)?"), TranslateT("Reset contact picture"), MB_YESNO) == IDYES) {
if ( !db_get_ts(hContact, "ContactPhoto", "File", &dbv)) {
DeleteFile(dbv.ptszVal);
diff --git a/plugins/AVS/src/utils.cpp b/plugins/AVS/src/utils.cpp index 35bebb621b..721d93282e 100644 --- a/plugins/AVS/src/utils.cpp +++ b/plugins/AVS/src/utils.cpp @@ -47,7 +47,7 @@ int _DebugTrace(MCONTACT hContact, const char *fmt, ...) char *proto = NULL;
if (hContact != NULL)
{
- name = (char*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, 0);
+ name = (char*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, 0);
proto = GetContactProto(hContact);
}
@@ -514,7 +514,7 @@ MCONTACT GetContactThatHaveTheAvatar(MCONTACT hContact, int locked) locked = db_get_b(hContact, "ContactPhoto", "Locked", 0);
if (!locked)
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
}
}
return hContact;
diff --git a/plugins/AddContactPlus/src/addcontact.cpp b/plugins/AddContactPlus/src/addcontact.cpp index 6b0e2e99f3..bc33ab425e 100644 --- a/plugins/AddContactPlus/src/addcontact.cpp +++ b/plugins/AddContactPlus/src/addcontact.cpp @@ -282,7 +282,7 @@ INT_PTR CALLBACK AddContactDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lp int item = SendDlgItemMessage(hdlg, IDC_GROUP, CB_GETCURSEL, 0, 0);
if (item > 0) {
item = SendDlgItemMessage(hdlg, IDC_GROUP, CB_GETITEMDATA, item, 0);
- CallService(MS_CLIST_CONTACTCHANGEGROUP, (WPARAM)hContact, item);
+ CallService(MS_CLIST_CONTACTCHANGEGROUP, hContact, item);
}
if (!IsDlgButtonChecked(hdlg, IDC_ADDTEMP)) {
@@ -304,7 +304,7 @@ INT_PTR CALLBACK AddContactDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lp }
if (GetAsyncKeyState(VK_CONTROL))
- CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, (LPARAM)(const char*)NULL);
+ CallService(MS_MSG_SENDMESSAGE, hContact, (LPARAM)(const char*)NULL);
}
// fall through
case IDCANCEL:
diff --git a/plugins/Alarms/src/alarms.cpp b/plugins/Alarms/src/alarms.cpp index eecc9c8bc9..a7e8e391bb 100644 --- a/plugins/Alarms/src/alarms.cpp +++ b/plugins/Alarms/src/alarms.cpp @@ -67,7 +67,7 @@ static LRESULT CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPA void ShowPopup(MCONTACT hContact, const TCHAR *msg)
{
if (ServiceExists(MS_POPUP_ADDPOPUPT)) {
- TCHAR *lpzContactName = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *lpzContactName = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
POPUPDATAT ppd = { 0 };
ppd.lchContact = hContact; //Be sure to use a GOOD handle, since this will not be checked.
diff --git a/plugins/AssocMgr/src/test.cpp b/plugins/AssocMgr/src/test.cpp index 5031919711..924e215c11 100644 --- a/plugins/AssocMgr/src/test.cpp +++ b/plugins/AssocMgr/src/test.cpp @@ -145,7 +145,7 @@ static int ServiceParseAimLink(WPARAM wParam,LPARAM lParam) db_set_b(hContact,MOD_KEY_CL,AIM_KEY_NL,1);
}
if(hContact!=NULL)
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,(LPARAM)msg);
+ CallService(MS_MSG_SENDMESSAGE,hContact,(LPARAM)msg);
}
return 0;
}
@@ -304,7 +304,7 @@ static void MessageIcqUser(ICQFILEINFO *info) if(ServiceExists(MS_MSG_SENDMESSAGE)) {
hContact=HContactFromUIN(atoi(info->uin),NULL); /* adds the contact if needed */
if(hContact!=NULL)
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,0);
+ CallService(MS_MSG_SENDMESSAGE,hContact,0);
}
}
@@ -458,7 +458,7 @@ static int ServiceParseYmsgrLink(WPARAM wParam,LPARAM lParam) if(ServiceExists(MS_MSG_SENDMESSAGE)) { /* does not yet check if sn is current user */
hContact=add_buddy(id,id,PALF_TEMPORARY); /* ensure contact is on list */
if(hContact!=NULL)
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,(LPARAM)msg);
+ CallService(MS_MSG_SENDMESSAGE,hContact,(LPARAM)msg);
}
return 0;
}
@@ -575,7 +575,7 @@ static int ServiceParseMsnimLink(WPARAM wParam,LPARAM lParam) if(ServiceExists(MS_MSG_SENDMESSAGE)) {
hContact=MSN_HContactFromEmail(email,email,TRUE,TRUE); /* does not yet check if email is current user */
if(hContact!=NULL)
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,0);
+ CallService(MS_MSG_SENDMESSAGE,hContact,0);
}
return 0;
}
@@ -641,7 +641,7 @@ static int ServiceParseLink(WPARAM wParam,LPARAM lParam) if(ServiceExists(MS_MSG_SENDMESSAGE)) {
hContact=gg_getcontact(atoi(arg),TRUE,FALSE,arg);
if(hContact!=NULL)
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,0);
+ CallService(MS_MSG_SENDMESSAGE,hContact,0);
}
}
return 0;
@@ -733,7 +733,7 @@ static int ServiceParseXmppURI(WPARAM wParam,LPARAM lParam) body=msg;
} else if(body==NULL) body=subj;
if(hContact!=NULL)
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,(LPARAM)body);
+ CallService(MS_MSG_SENDMESSAGE,hContact,(LPARAM)body);
}
return 0;
}
@@ -757,7 +757,7 @@ static int ServiceParseXmppURI(WPARAM wParam,LPARAM lParam) MCONTACT hContact;
hContact=JabberHContactFromJID(jid);
if(hContact==NULL) /* not yet implemented: show standard miranda dialog here */
- CallService(MS_DB_CONTACT_DELETE,(WPARAM)hContact,0);
+ CallService(MS_DB_CONTACT_DELETE,hContact,0);
return 0;
}
/* add user subscription */
diff --git a/plugins/AuthState/src/main.cpp b/plugins/AuthState/src/main.cpp index f8498223b6..6d2223af71 100644 --- a/plugins/AuthState/src/main.cpp +++ b/plugins/AuthState/src/main.cpp @@ -173,7 +173,7 @@ int onModulesLoaded(WPARAM wParam,LPARAM lParam) // Set initial value for all contacts
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- onExtraImageApplying((WPARAM)hContact, 1);
+ onExtraImageApplying(hContact, 1);
hOptInitialise = HookEvent(ME_OPT_INITIALISE, onOptInitialise);
if (bContactMenuItem)
diff --git a/plugins/AuthState/src/options.cpp b/plugins/AuthState/src/options.cpp index 9e1f972f55..fafd1d115b 100644 --- a/plugins/AuthState/src/options.cpp +++ b/plugins/AuthState/src/options.cpp @@ -56,7 +56,7 @@ INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP bIconsForRecentContacts = IsDlgButtonChecked(hwndDlg, IDC_ICONSFORRECENT);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- onExtraImageApplying((WPARAM)hContact,0);
+ onExtraImageApplying(hContact,0);
//Store options values to DB
db_set_b(NULL, MODULENAME, "EnableAuthIcon", bUseAuthIcon);
diff --git a/plugins/AvatarHistory/src/AvatarDlg.cpp b/plugins/AvatarHistory/src/AvatarDlg.cpp index 86fad5edce..da042e79e4 100644 --- a/plugins/AvatarHistory/src/AvatarDlg.cpp +++ b/plugins/AvatarHistory/src/AvatarDlg.cpp @@ -556,7 +556,7 @@ int ShowSaveDialog(HWND hwnd, TCHAR* fn, MCONTACT hContact) lstrcpyn(file, _tcsrchr(fn, '\\')+1, sizeof(file));
ofn.lpstrFile = file;
- TCHAR *displayName = (TCHAR*) CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR);
+ TCHAR *displayName = (TCHAR*) CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR);
if (displayName)
{
TCHAR title[MAX_PATH];
diff --git a/plugins/AvatarHistory/src/popup.cpp b/plugins/AvatarHistory/src/popup.cpp index af2de3d9ad..97e7c594b4 100644 --- a/plugins/AvatarHistory/src/popup.cpp +++ b/plugins/AvatarHistory/src/popup.cpp @@ -107,7 +107,7 @@ void ShowPopupEx(MCONTACT hContact, const TCHAR *title, const TCHAR *description if (title != NULL)
lstrcpyn(ppd.lptzContactName, title, SIZEOF(ppd.lptzContactName));
else if (hContact != NULL)
- lstrcpyn(ppd.lptzContactName, (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR),
+ lstrcpyn(ppd.lptzContactName, (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR),
SIZEOF(ppd.lptzContactName));
if (description != NULL)
@@ -174,7 +174,7 @@ void ShowPopupEx(MCONTACT hContact, const TCHAR *title, const TCHAR *description }
else
{
- MessageBox(NULL, description, title ? title : (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR),
+ MessageBox(NULL, description, title ? title : (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR),
MB_OK);
}
diff --git a/plugins/BasicHistory/src/EventList.cpp b/plugins/BasicHistory/src/EventList.cpp index d0f63d679e..420d25072a 100644 --- a/plugins/BasicHistory/src/EventList.cpp +++ b/plugins/BasicHistory/src/EventList.cpp @@ -433,7 +433,7 @@ std::wstring EventList::GetMyName() inline std::wstring GetProtocolName(MCONTACT hContact)
{
- char* ac = (char *)CallService(MS_PROTO_GETCONTACTBASEACCOUNT, (WPARAM)hContact, 0);
+ char* ac = (char *)CallService(MS_PROTO_GETCONTACTBASEACCOUNT, hContact, 0);
std::wstring proto1;
if (ac != NULL) {
PROTOACCOUNT* acnt = ProtoGetAccount(ac);
diff --git a/plugins/BasicHistory/src/HistoryWindow.cpp b/plugins/BasicHistory/src/HistoryWindow.cpp index e14e778552..19b39af3bf 100644 --- a/plugins/BasicHistory/src/HistoryWindow.cpp +++ b/plugins/BasicHistory/src/HistoryWindow.cpp @@ -1668,7 +1668,7 @@ void HistoryWindow::ReloadContacts() }
if (hContact != NULL) {
- HANDLE hItem = (HANDLE)SendMessage(contactList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(contactList, CLM_FINDCONTACT, hContact, 0);
if (hItem != NULL) {
SendMessage(contactList, CLM_ENSUREVISIBLE, (WPARAM)hItem, 0);
SendMessage(contactList, CLM_SELECTITEM, (WPARAM)hItem, 0);
@@ -2130,7 +2130,7 @@ void HistoryWindow::Delete(int what) toDelete = (int)end;
}
else {
- DeleteAllUserHistory((WPARAM)hContact, 0);
+ DeleteAllUserHistory(hContact, 0);
return;
}
diff --git a/plugins/Boltun/src/actionQueue.cpp b/plugins/Boltun/src/actionQueue.cpp index 1c3bf5a25c..ac7e76c06e 100644 --- a/plugins/Boltun/src/actionQueue.cpp +++ b/plugins/Boltun/src/actionQueue.cpp @@ -120,7 +120,7 @@ static void TimerAnswer(MCONTACT hContact, const TalkBot::MessageInfo* info) static void StartTyping(MCONTACT hContact, const TalkBot::MessageInfo*)
{
- CallService(MS_PROTO_SELFISTYPING, (WPARAM)hContact,
+ CallService(MS_PROTO_SELFISTYPING, hContact,
(LPARAM)PROTOTYPE_SELFTYPING_ON);
typingContactsLock.Enter();
typingContacts.insert(hContact);
@@ -192,7 +192,7 @@ void DoAnswer(MCONTACT hContact, const TalkBot::MessageInfo *info, bool sticky = typingContactsLock.Enter();
if (typingContacts.find(hContact) != typingContacts.end())
{
- CallService(MS_PROTO_SELFISTYPING, (WPARAM)hContact, (LPARAM)PROTOTYPE_SELFTYPING_OFF);
+ CallService(MS_PROTO_SELFISTYPING, hContact, (LPARAM)PROTOTYPE_SELFTYPING_OFF);
typingContacts.erase(hContact);
}
typingContactsLock.Leave();
diff --git a/plugins/BuddyExpectator/src/BuddyExpectator.cpp b/plugins/BuddyExpectator/src/BuddyExpectator.cpp index 6bea40587e..23b3aa2bd2 100644 --- a/plugins/BuddyExpectator/src/BuddyExpectator.cpp +++ b/plugins/BuddyExpectator/src/BuddyExpectator.cpp @@ -233,7 +233,7 @@ bool isContactGoneFor(MCONTACT hContact, int days) ppd.lchIcon = Skin_GetIcon("enabled_icon");
mir_sntprintf(ppd.lptzContactName, MAX_CONTACTNAME, TranslateT("Hiding %s (%S)"),
- CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR),
+ CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR),
GetContactProto(hContact));
mir_sntprintf(ppd.lptzText, MAX_SECONDLINE, TranslateT("%d days since last message"), daysSinceMessage);
@@ -269,7 +269,7 @@ void ReturnNotify(MCONTACT hContact, TCHAR *message) POPUPDATAT ppd = { 0 };
ppd.lchContact = hContact;
ppd.lchIcon = hIcon;
- _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR), MAX_CONTACTNAME);
+ _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR), MAX_CONTACTNAME);
_tcsncpy(ppd.lptzText, message, MAX_SECONDLINE);
if (!options.iUsePopupColors) {
ppd.colorBack = options.iPopupColorBack;
@@ -288,7 +288,7 @@ void ReturnNotify(MCONTACT hContact, TCHAR *message) cle.pszService = "BuddyExpectator/actionReturned";
cle.flags = CLEF_TCHAR;
- TCHAR* nick = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR);
+ TCHAR* nick = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR);
TCHAR tmpMsg[512];
mir_sntprintf(tmpMsg, 512, _T("%s %s"), nick, message);
cle.ptszTooltip = tmpMsg;
@@ -307,7 +307,7 @@ void GoneNotify(MCONTACT hContact, TCHAR *message) POPUPDATAT ppd = {0};
ppd.lchContact = hContact;
ppd.lchIcon = hIcon;
- _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR), MAX_CONTACTNAME);
+ _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR), MAX_CONTACTNAME);
_tcsncpy(ppd.lptzText, message, MAX_SECONDLINE);
if (!options.iUsePopupColors) {
ppd.colorBack = options.iPopupColorBack;
@@ -326,7 +326,7 @@ void GoneNotify(MCONTACT hContact, TCHAR *message) cle.hIcon = hIcon;
cle.pszService = "BuddyExpectator/actionStillAbsent";
- TCHAR* nick = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR);
+ TCHAR* nick = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR);
TCHAR tmpMsg[512];
mir_sntprintf(tmpMsg, 512, _T("%s %s"), nick, message);
cle.ptszTooltip = tmpMsg;
@@ -350,7 +350,7 @@ INT_PTR MissYouAction(WPARAM wParam, LPARAM lParam) }
else hContact = wParam;
- CallService(MS_MSG_SENDMESSAGET, (WPARAM)hContact, 0);
+ CallService(MS_MSG_SENDMESSAGET, hContact, 0);
return 0;
}
@@ -369,10 +369,10 @@ INT_PTR ContactReturnedAction(WPARAM wParam, LPARAM lParam) else hContact = wParam;
if (options.iShowMessageWindow>0)
- CallService(MS_MSG_SENDMESSAGET, (WPARAM)hContact, 0);
+ CallService(MS_MSG_SENDMESSAGET, hContact, 0);
if (options.iShowUDetails>0)
- CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
+ CallService(MS_USERINFO_SHOWDIALOG, hContact, 0);
setLastSeen(hContact);
return 0;
@@ -394,13 +394,13 @@ INT_PTR ContactStillAbsentAction(WPARAM wParam, LPARAM lParam) switch (options.action2) {
case GCA_DELETE:
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0);
+ CallService(MS_DB_CONTACT_DELETE, hContact, 0);
break;
case GCA_UDETAILS:
- CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
+ CallService(MS_USERINFO_SHOWDIALOG, hContact, 0);
break;
case GCA_MESSAGE:
- CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
+ CallService(MS_MSG_SENDMESSAGE, hContact, 0);
break;
case GCA_NOACTION:
break;
@@ -505,7 +505,7 @@ int SettingChanged(WPARAM wParam, LPARAM lParam) ppd.lchContact = hContact;
ppd.lchIcon = Skin_GetIcon("enabled_icon");
- _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR), MAX_CONTACTNAME);
+ _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR), MAX_CONTACTNAME);
_tcsncpy(ppd.lptzText, TranslateT("You awaited this contact!"), MAX_SECONDLINE);
if (!options.iUsePopupColors) {
ppd.colorBack = options.iPopupColorBack;
diff --git a/plugins/BuddyPounce/src/dialog.cpp b/plugins/BuddyPounce/src/dialog.cpp index 3e7ccc182e..fee3cd0523 100644 --- a/plugins/BuddyPounce/src/dialog.cpp +++ b/plugins/BuddyPounce/src/dialog.cpp @@ -16,7 +16,7 @@ void populateContacts(MCONTACT BPhContact, HWND hwnd2CB) char *szProto = GetContactProto(hContact);
if (szProto && (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_IM)) {
TCHAR name[300];
- mir_sntprintf(name, SIZEOF(name), _T("%s (%s)"), CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR), _A2T(szProto));
+ mir_sntprintf(name, SIZEOF(name), _T("%s (%s)"), CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR), _A2T(szProto));
int index = SendMessage(hwnd2CB, CB_ADDSTRING, 0, (LPARAM)name);
SendMessage(hwnd2CB, CB_SETITEMDATA, index, (LPARAM)hContact);
if (BPhContact == hContact)
@@ -613,12 +613,12 @@ void CreateMessageAcknowlegedWindow(MCONTACT hContact, int SentSuccess) HWND hwnd = CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_CONFIRMSEND), 0, PounceSentDlgProc, (LPARAM)hContact);
TCHAR msg[256];
if (SentSuccess) {
- mir_sntprintf(msg, SIZEOF(msg), TranslateT("Message successfully sent to %s"), CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Message successfully sent to %s"), CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR));
SetWindowText(GetDlgItem(hwnd, IDOK), TranslateT("OK"));
ShowWindow(GetDlgItem(hwnd, IDCANCEL), 0);
}
else {
- mir_sntprintf(msg, SIZEOF(msg), TranslateT("Message failed to send to %s"), CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Message failed to send to %s"), CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR));
SetWindowText(GetDlgItem(hwnd, IDOK), TranslateT("Retry"));
}
SetWindowText(GetDlgItem(hwnd, LBL_CONTACT), msg);
diff --git a/plugins/BuddyPounce/src/main.cpp b/plugins/BuddyPounce/src/main.cpp index dbff32ad1f..ba13bc78d9 100644 --- a/plugins/BuddyPounce/src/main.cpp +++ b/plugins/BuddyPounce/src/main.cpp @@ -226,7 +226,7 @@ INT_PTR AddToPounce(WPARAM wParam, LPARAM lParam) mir_free(newPounce);
db_free(&dbv);
}
- else AddSimpleMessage((WPARAM)hContact, (LPARAM)message);
+ else AddSimpleMessage(hContact, (LPARAM)message);
return 0;
}
diff --git a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp index 5df2197e37..178c252ea9 100644 --- a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp +++ b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp @@ -87,7 +87,7 @@ void Popup_DoAction(HWND hWnd, BYTE Action, PLUGIN_DATA *pdata) switch (Action) {
case PCA_OPENMESSAGEWND: // open message window
if (hContact && hContact != INVALID_CONTACT_ID)
- CallServiceSync(ServiceExists("SRMsg/LaunchMessageWindow") ? "SRMsg/LaunchMessageWindow" : MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
+ CallServiceSync(ServiceExists("SRMsg/LaunchMessageWindow") ? "SRMsg/LaunchMessageWindow" : MS_MSG_SENDMESSAGE, hContact, 0);
break;
case PCA_OPENMENU: // open contact menu
@@ -97,12 +97,12 @@ void Popup_DoAction(HWND hWnd, BYTE Action, PLUGIN_DATA *pdata) case PCA_OPENDETAILS: // open contact details window
if (hContact != INVALID_CONTACT_ID)
- CallServiceSync(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
+ CallServiceSync(MS_USERINFO_SHOWDIALOG, hContact, 0);
break;
case PCA_OPENHISTORY: // open contact history
if (hContact != INVALID_CONTACT_ID)
- CallServiceSync(MS_HISTORY_SHOWCONTACTHISTORY, (WPARAM)hContact, 0);
+ CallServiceSync(MS_HISTORY_SHOWCONTACTHISTORY, hContact, 0);
break;
case PCA_OPENLOG: // open log file
@@ -230,7 +230,7 @@ int ContactSettingChanged(WPARAM hContact, LPARAM lParam) PopupOptPage.DBToMem();
}
- MCONTACT hContactOrMeta = (hContact && bMetaContactsExists) ? (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0) : hContact;
+ MCONTACT hContactOrMeta = (hContact && bMetaContactsExists) ? (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0) : hContact;
if (!hContactOrMeta)
hContactOrMeta = hContact;
@@ -286,7 +286,7 @@ int ContactSettingChanged(WPARAM hContact, LPARAM lParam) if (uid && (INT_PTR)uid != CALLSERVICE_NOTFOUND)
szUID = DBGetContactSettingAsString(hContact, szProto, uid, _T(""));
- logservice_log(LOG_ID, hContact, TCString((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR)) + _T(" (") + szUID + TranslateT(") changed client to ") + ClientName);
+ logservice_log(LOG_ID, hContact, TCString((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR)) + _T(" (") + szUID + TranslateT(") changed client to ") + ClientName);
}
}
_ASSERT(sd.MirVer.GetLen()); // save the last known MirVer value even if the new one is empty
diff --git a/plugins/Clist_modern/src/modern_clistsettings.cpp b/plugins/Clist_modern/src/modern_clistsettings.cpp index 5db5e9857f..bf06c8efda 100644 --- a/plugins/Clist_modern/src/modern_clistsettings.cpp +++ b/plugins/Clist_modern/src/modern_clistsettings.cpp @@ -356,7 +356,7 @@ char *GetContactCachedProtocol(MCONTACT hContact) char* GetProtoForContact(MCONTACT hContact)
{
- return (char*)CallService(MS_PROTO_GETCONTACTBASEACCOUNT,(WPARAM)hContact,0);
+ return (char*)CallService(MS_PROTO_GETCONTACTBASEACCOUNT,hContact,0);
}
int GetStatusForContact(MCONTACT hContact,char *szProto)
diff --git a/plugins/Clist_modern/src/modern_viewmodebar.cpp b/plugins/Clist_modern/src/modern_viewmodebar.cpp index 135448605c..2dc289494b 100644 --- a/plugins/Clist_modern/src/modern_viewmodebar.cpp +++ b/plugins/Clist_modern/src/modern_viewmodebar.cpp @@ -167,7 +167,7 @@ static void ShowPage(HWND hwnd, int page) static int UpdateClistItem(MCONTACT hContact, DWORD mask)
{
for (int i = ID_STATUS_OFFLINE; i <= ID_STATUS_OUTTOLUNCH; i++)
- SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_SETEXTRAIMAGE, (WPARAM)hContact, MAKELONG(i - ID_STATUS_OFFLINE,
+ SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_SETEXTRAIMAGE, hContact, MAKELONG(i - ID_STATUS_OFFLINE,
(1 << (i - ID_STATUS_OFFLINE)) & mask ? i - ID_STATUS_OFFLINE : nullImage));
return 0;
@@ -189,7 +189,7 @@ static void UpdateStickies() int i;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- MCONTACT hItem = (MCONTACT)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ MCONTACT hItem = (MCONTACT)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem)
SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, (BYTE)db_get_dw(hContact, CLVM_MODULE, g_szModename, 0) ? 1 : 0);
localMask = HIWORD(db_get_dw(hContact, CLVM_MODULE, g_szModename, 0));
@@ -451,7 +451,7 @@ void SaveState() DWORD dwGlobalMask = GetMaskForItem(hInfoItem);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem == NULL)
continue;
@@ -845,7 +845,7 @@ INT_PTR CALLBACK DlgProcViewModesSetup(HWND hwndDlg, UINT msg, WPARAM wParam, LP case IDC_CLEARALL:
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem)
SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, 0);
}
diff --git a/plugins/Clist_mw/src/clcitems.cpp b/plugins/Clist_mw/src/clcitems.cpp index 5bccc89885..703ae72ad4 100644 --- a/plugins/Clist_mw/src/clcitems.cpp +++ b/plugins/Clist_mw/src/clcitems.cpp @@ -135,7 +135,7 @@ static struct ClcContact* AddContactToGroup(struct ClcData *dat,ClcGroup *group, group->cl.items[i]->subcontacts = NULL;
if (ProtoServiceExists(cacheEntry->szProto, PS_GETADVANCEDSTATUSICON))
- img = ProtoCallService(cacheEntry->szProto, PS_GETADVANCEDSTATUSICON, (WPARAM)hContact, 0);
+ img = ProtoCallService(cacheEntry->szProto, PS_GETADVANCEDSTATUSICON, hContact, 0);
if (img == -1 || !(LOWORD(img)))
img = pcli->pfnGetContactIcon(hContact);
diff --git a/plugins/Clist_mw/src/contact.cpp b/plugins/Clist_mw/src/contact.cpp index 1f24968256..4f2fe4b3d7 100644 --- a/plugins/Clist_mw/src/contact.cpp +++ b/plugins/Clist_mw/src/contact.cpp @@ -63,8 +63,8 @@ static int GetContactStatus(MCONTACT hContact) void ChangeContactIcon(MCONTACT hContact,int iIcon,int add)
{
//clui MS_CLUI_CONTACTADDED MS_CLUI_CONTACTSETICON this methods is null
- //CallService(add?MS_CLUI_CONTACTADDED:MS_CLUI_CONTACTSETICON,(WPARAM)hContact,iIcon);
- NotifyEventHooks(hContactIconChangedEvent,(WPARAM)hContact,iIcon);
+ //CallService(add?MS_CLUI_CONTACTADDED:MS_CLUI_CONTACTSETICON,hContact,iIcon);
+ NotifyEventHooks(hContactIconChangedEvent,hContact,iIcon);
}
static int GetStatusModeOrdering(int statusMode)
diff --git a/plugins/Clist_nicer/src/clc.cpp b/plugins/Clist_nicer/src/clc.cpp index 9f3f15c3bf..f9550d81c4 100644 --- a/plugins/Clist_nicer/src/clc.cpp +++ b/plugins/Clist_nicer/src/clc.cpp @@ -582,7 +582,7 @@ LBL_Def: if (contact) {
if (ProtoServiceExists(szProto, PS_GETADVANCEDSTATUSICON)) {
- int iconId = ProtoCallService(szProto, PS_GETADVANCEDSTATUSICON, (WPARAM)hContact, 0);
+ int iconId = ProtoCallService(szProto, PS_GETADVANCEDSTATUSICON, hContact, 0);
if (iconId != -1)
contact->xStatusIcon = iconId >> 16;
}
diff --git a/plugins/Clist_nicer/src/clcitems.cpp b/plugins/Clist_nicer/src/clcitems.cpp index 856dfe77e7..421e588307 100644 --- a/plugins/Clist_nicer/src/clcitems.cpp +++ b/plugins/Clist_nicer/src/clcitems.cpp @@ -105,7 +105,7 @@ int AddContactToGroup(struct ClcData *dat, ClcGroup *group, MCONTACT hContact) else
p->bIsMeta = FALSE;
if (p->bIsMeta && cfg::dat.bMetaAvail && !(cfg::dat.dwFlags & CLUI_USEMETAICONS)) {
- p->hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ p->hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
p->metaProto = GetContactProto(p->hSubContact);
p->iImage = pcli->pfnGetContactIcon(p->hSubContact);
}
@@ -266,11 +266,11 @@ BYTE GetCachedStatusMsg(TExtraCache *p, char *szProto) CUSTOM_STATUS cst = { sizeof(cst) };
cst.flags = CSSF_MASK_STATUS;
cst.status = &xStatus;
- if (ProtoServiceExists(szProto, PS_GETCUSTOMSTATUSEX) && !ProtoCallService(szProto, PS_GETCUSTOMSTATUSEX, (WPARAM)hContact, (LPARAM)&cst) && xStatus > 0) {
+ if (ProtoServiceExists(szProto, PS_GETCUSTOMSTATUSEX) && !ProtoCallService(szProto, PS_GETCUSTOMSTATUSEX, hContact, (LPARAM)&cst) && xStatus > 0) {
cst.flags = CSSF_MASK_NAME | CSSF_DEFAULT_NAME | CSSF_TCHAR;
cst.wParam = &xStatus2;
cst.ptszName = xStatusName;
- if ( !CallProtoService(szProto, PS_GETCUSTOMSTATUSEX, (WPARAM)hContact, (LPARAM)&cst)) {
+ if ( !CallProtoService(szProto, PS_GETCUSTOMSTATUSEX, hContact, (LPARAM)&cst)) {
TCHAR *szwXstatusName = TranslateTS(xStatusName);
p->statusMsg = (TCHAR *)realloc(p->statusMsg, (lstrlen(szwXstatusName) + 2) * sizeof(TCHAR));
_tcsncpy(p->statusMsg, szwXstatusName, lstrlen(szwXstatusName) + 1);
diff --git a/plugins/Clist_nicer/src/clistevents.cpp b/plugins/Clist_nicer/src/clistevents.cpp index 613936a45d..56ac5500b9 100644 --- a/plugins/Clist_nicer/src/clistevents.cpp +++ b/plugins/Clist_nicer/src/clistevents.cpp @@ -375,10 +375,10 @@ int RemoveEvent(MCONTACT hContact, HANDLE hDbEvent) if (bUnstick) {
// clear "sticky" (sort) status
- hItem = (HANDLE)SendMessage(pcli->hwndContactTree, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ hItem = (HANDLE)SendMessage(pcli->hwndContactTree, CLM_FINDCONTACT, hContact, 0);
if (hItem) {
SendMessage(pcli->hwndContactTree, CLM_SETSTICKY, (WPARAM) hItem, 0);
- pcli->pfnClcBroadcast(INTM_PROTOCHANGED, (WPARAM)hContact, 0);
+ pcli->pfnClcBroadcast(INTM_PROTOCHANGED, hContact, 0);
} }
if (hContact == cfg::dat.hUpdateContact || (INT_PTR)hDbEvent == 1)
diff --git a/plugins/Clist_nicer/src/clistmenus.cpp b/plugins/Clist_nicer/src/clistmenus.cpp index c71996de4c..74498cab6a 100644 --- a/plugins/Clist_nicer/src/clistmenus.cpp +++ b/plugins/Clist_nicer/src/clistmenus.cpp @@ -81,7 +81,7 @@ static INT_PTR CALLBACK IgnoreDialogProc(HWND hWnd, UINT msg, WPARAM wParam, LPA hContact = lParam;
SetWindowLongPtr(hWnd, GWLP_USERDATA, (LONG_PTR)hContact);
dwMask = cfg::getDword(hContact, "Ignore", "Mask1", 0);
- SendMessage(hWnd, WM_USER + 100, (WPARAM)hContact, dwMask);
+ SendMessage(hWnd, WM_USER + 100, hContact, dwMask);
SendMessage(hWnd, WM_USER + 120, 0, 0);
TranslateDialogDefault(hWnd);
hwndAdd = GetDlgItem(hWnd, IDC_IGN_ADDPERMANENTLY); // CreateWindowEx(0, _T("CLCButtonClass"), _T("FOO"), WS_VISIBLE | BS_PUSHBUTTON | WS_CHILD | WS_TABSTOP, 200, 276, 106, 24, hWnd, (HMENU)IDC_IGN_ADDPERMANENTLY, g_hInst, NULL);
@@ -121,7 +121,7 @@ static INT_PTR CALLBACK IgnoreDialogProc(HWND hWnd, UINT msg, WPARAM wParam, LPA DWORD dwXMask = cfg::getDword(hContact, "CList", "CLN_xmask", 0);
int i = 0;
- mir_sntprintf(szTitle, 512, TranslateT("Contact list display and ignore options for %s"), contact ? contact->szText : (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
+ mir_sntprintf(szTitle, 512, TranslateT("Contact list display and ignore options for %s"), contact ? contact->szText : (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR));
SetWindowText(hWnd, szTitle);
SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA));
@@ -167,13 +167,13 @@ static INT_PTR CALLBACK IgnoreDialogProc(HWND hWnd, UINT msg, WPARAM wParam, LPA case WM_COMMAND:
switch(LOWORD(wParam)) {
case IDC_IGN_PRIORITY:
- SendMessage(pcli->hwndContactTree, CLM_TOGGLEPRIORITYCONTACT, (WPARAM)hContact, 0);
+ SendMessage(pcli->hwndContactTree, CLM_TOGGLEPRIORITYCONTACT, hContact, 0);
return 0;
case IDC_IGN_ALL:
- SendMessage(hWnd, WM_USER + 100, (WPARAM)hContact, (LPARAM)0xffffffff);
+ SendMessage(hWnd, WM_USER + 100, hContact, (LPARAM)0xffffffff);
return 0;
case IDC_IGN_NONE:
- SendMessage(hWnd, WM_USER + 100, (WPARAM)hContact, 0);
+ SendMessage(hWnd, WM_USER + 100, hContact, 0);
return 0;
case IDC_IGN_ALWAYSONLINE:
if (IsDlgButtonChecked(hWnd, IDC_IGN_ALWAYSONLINE))
diff --git a/plugins/Clist_nicer/src/clistmod.cpp b/plugins/Clist_nicer/src/clistmod.cpp index 2a838b39dc..74bb93ffad 100644 --- a/plugins/Clist_nicer/src/clistmod.cpp +++ b/plugins/Clist_nicer/src/clistmod.cpp @@ -55,7 +55,7 @@ int IconFromStatusMode(const char *szProto, int status, MCONTACT hContact, HICON int finalStatus;
if (szProto != NULL && !strcmp(szProto, cfg::dat.szMetaName) && cfg::dat.bMetaAvail && hContact != 0 && !(cfg::dat.dwFlags & CLUI_USEMETAICONS)) {
- MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
szFinalProto = GetContactProto(hSubContact);
finalStatus = (status == 0) ? (WORD) cfg::getWord(hSubContact, szFinalProto, "Status", ID_STATUS_OFFLINE) : status;
hContact = hSubContact;
diff --git a/plugins/Clist_nicer/src/clui.cpp b/plugins/Clist_nicer/src/clui.cpp index 5772d3a0a4..763cb363cb 100644 --- a/plugins/Clist_nicer/src/clui.cpp +++ b/plugins/Clist_nicer/src/clui.cpp @@ -721,7 +721,7 @@ static int ServiceParamsOK(ButtonItem *item, WPARAM *wParam, LPARAM *lParam, MCO return 0;
if (item->dwFlags & BUTTON_PASSHCONTACTW)
- *wParam = (WPARAM)hContact;
+ *wParam = hContact;
else if (item->dwFlags & BUTTON_PASSHCONTACTL)
*lParam = (LPARAM)hContact;
}
diff --git a/plugins/Clist_nicer/src/viewmodes.cpp b/plugins/Clist_nicer/src/viewmodes.cpp index cd163a2f36..0be4ed7741 100644 --- a/plugins/Clist_nicer/src/viewmodes.cpp +++ b/plugins/Clist_nicer/src/viewmodes.cpp @@ -123,7 +123,7 @@ static void ShowPage(HWND hwnd, int page) static int UpdateClistItem(MCONTACT hContact, DWORD mask)
{
for (int i = ID_STATUS_OFFLINE; i <= ID_STATUS_OUTTOLUNCH; i++)
- SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_SETEXTRAIMAGE, (WPARAM)hContact, MAKELONG(i - ID_STATUS_OFFLINE,
+ SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_SETEXTRAIMAGE, hContact, MAKELONG(i - ID_STATUS_OFFLINE,
(1 << (i - ID_STATUS_OFFLINE)) & mask ? i - ID_STATUS_OFFLINE : nullImage));
return 0;
@@ -142,7 +142,7 @@ static DWORD GetMaskForItem(HANDLE hItem) static void UpdateStickies()
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- MCONTACT hItem = (MCONTACT)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ MCONTACT hItem = (MCONTACT)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem)
SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, cfg::getByte(hContact, "CLVM", g_szModename, 0) ? 1 : 0);
DWORD localMask = HIWORD(cfg::getDword(hContact, "CLVM", g_szModename, 0));
@@ -394,7 +394,7 @@ void SaveState() dwGlobalMask = GetMaskForItem(hInfoItem);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- hItem = (HANDLE)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ hItem = (HANDLE)SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem) {
if (SendDlgItemMessage(clvmHwnd, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItem, 0)) {
dwLocalMask = GetMaskForItem(hItem);
@@ -719,7 +719,7 @@ INT_PTR CALLBACK DlgProcViewModesSetup(HWND hwndDlg, UINT msg, WPARAM wParam, LP case IDC_CLEARALL:
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem)
SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, 0);
}
diff --git a/plugins/ContactsPlus/src/main.cpp b/plugins/ContactsPlus/src/main.cpp index d8812192b9..549685e941 100644 --- a/plugins/ContactsPlus/src/main.cpp +++ b/plugins/ContactsPlus/src/main.cpp @@ -98,7 +98,7 @@ static void ProcessUnreadEvents(void) db_event_get(hDbEvent, &dbei);
if (!(dbei.flags & (DBEF_SENT | DBEF_READ)) && dbei.eventType == EVENTTYPE_CONTACTS) {
//process the event
- HookDBEventAdded((WPARAM)hContact, (LPARAM)hDbEvent);
+ HookDBEventAdded(hContact, (LPARAM)hDbEvent);
}
hDbEvent = db_event_next(hDbEvent);
}
diff --git a/plugins/ContactsPlus/src/receive.cpp b/plugins/ContactsPlus/src/receive.cpp index 6b79314c20..f7564631b1 100644 --- a/plugins/ContactsPlus/src/receive.cpp +++ b/plugins/ContactsPlus/src/receive.cpp @@ -321,7 +321,7 @@ INT_PTR CALLBACK RecvDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara if (hContact && caGroup) {
// use newest group API if available
if (ServiceExists(MS_CLIST_CONTACTCHANGEGROUP))
- CallService(MS_CLIST_CONTACTCHANGEGROUP, (WPARAM)hContact, (LPARAM)nGroupId);
+ CallService(MS_CLIST_CONTACTCHANGEGROUP, hContact, (LPARAM)nGroupId);
else
db_set_ts(hContact, "CList", "Group", caGroup);
}
@@ -340,7 +340,7 @@ INT_PTR CALLBACK RecvDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara if (ListView_GetItemState(hLV, i, LVIS_SELECTED)) {
hContact = CreateTemporaryContactForItem(hwndDlg, wndData, i);
if (hContact)
- CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
+ CallService(MS_USERINFO_SHOWDIALOG, hContact, 0);
}
}
break;
@@ -368,13 +368,13 @@ INT_PTR CALLBACK RecvDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara case ID_POPUP_USERDETAILS:
hContact = CreateTemporaryContactForItem(hwndDlg, wndData, wndData->iPopupItem);
if (hContact)
- CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0 );
+ CallService(MS_USERINFO_SHOWDIALOG, hContact, 0 );
break;
case ID_POPUP_SENDMESSAGE:
hContact = CreateTemporaryContactForItem(hwndDlg, wndData, wndData->iPopupItem);
if (hContact)
- CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
+ CallService(MS_MSG_SENDMESSAGE, hContact, 0);
break;
case IDC_USERMENU:
diff --git a/plugins/ContactsPlus/src/send.cpp b/plugins/ContactsPlus/src/send.cpp index 5913a616d2..6bc4a8e915 100644 --- a/plugins/ContactsPlus/src/send.cpp +++ b/plugins/ContactsPlus/src/send.cpp @@ -197,7 +197,7 @@ static MCONTACT FindNextClistContact(HWND hList, MCONTACT hContact, MCONTACT *ph static MCONTACT FindFirstClistContact(HWND hList, MCONTACT *phItem)
{
MCONTACT hContact = db_find_first();
- MCONTACT hItem = (MCONTACT)SendMessage(hList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ MCONTACT hItem = (MCONTACT)SendMessage(hList, CLM_FINDCONTACT, hContact, 0);
if (hContact && !hItem)
return FindNextClistContact(hList, hContact, phItem);
diff --git a/plugins/CountryFlags/src/extraimg.cpp b/plugins/CountryFlags/src/extraimg.cpp index f7961c65bb..1ada5a8372 100644 --- a/plugins/CountryFlags/src/extraimg.cpp +++ b/plugins/CountryFlags/src/extraimg.cpp @@ -50,7 +50,7 @@ static void CALLBACK SetExtraImage(MCONTACT hContact) if (!bShowExtraIcon)
return;
- int countryNumber = ServiceDetectContactOriginCountry((WPARAM)hContact, 0);
+ int countryNumber = ServiceDetectContactOriginCountry(hContact, 0);
if (countryNumber == 0xFFFF && !bUseUnknown)
ExtraIcon_Clear(hExtraIcon, hContact);
else {
diff --git a/plugins/DbEditorPP/src/main_window.cpp b/plugins/DbEditorPP/src/main_window.cpp index 02b0c98c9b..efdf5599ec 100644 --- a/plugins/DbEditorPP/src/main_window.cpp +++ b/plugins/DbEditorPP/src/main_window.cpp @@ -128,7 +128,7 @@ LRESULT CALLBACK ModuleTreeSubclassProc(HWND hwnd,UINT msg,WPARAM wParam,LPARAM if (MessageBox(0,msg, Translate("Confirm Contact Delete"), MB_YESNO|MB_ICONEXCLAMATION) == IDNO)
break;
}
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact,0);
+ CallService(MS_DB_CONTACT_DELETE, hContact,0);
freeTree(hwnd,mtis->hContact);
TreeView_DeleteItem(hwnd,tvi.hItem);
}
diff --git a/plugins/DbEditorPP/src/modsettingenum.cpp b/plugins/DbEditorPP/src/modsettingenum.cpp index 42e21b67f0..a1a49bcf42 100644 --- a/plugins/DbEditorPP/src/modsettingenum.cpp +++ b/plugins/DbEditorPP/src/modsettingenum.cpp @@ -65,7 +65,7 @@ int EnumSettings(MCONTACT hContact, char* module, ModuleSettingLL *msll) dbces.lParam = (LPARAM)msll;
msll->first = 0;
msll->last = 0;
- return !CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ return !CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
}
int CheckIfModuleIsEmptyProc(const char *szSetting, LPARAM lParam)
@@ -78,7 +78,7 @@ int IsModuleEmpty(MCONTACT hContact, char* szModule) DBCONTACTENUMSETTINGS dbces;
dbces.pfnEnumProc = CheckIfModuleIsEmptyProc;
dbces.szModule = szModule;
- int retVal = CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ int retVal = CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
if (retVal >= 0)
return 0;
return 1;
diff --git a/plugins/DbEditorPP/src/moduletree.cpp b/plugins/DbEditorPP/src/moduletree.cpp index b6b150e7f5..7427e635a9 100644 --- a/plugins/DbEditorPP/src/moduletree.cpp +++ b/plugins/DbEditorPP/src/moduletree.cpp @@ -847,13 +847,13 @@ void moduleListRightClick(HWND hwnd, WPARAM wParam,LPARAM lParam) // hwnd here i char msg[1024];
mir_snprintf(msg, SIZEOF(msg), Translate("Are you sure you want to delete contact \"%s\"?"), module);
if (MessageBox(0,msg, Translate("Confirm Contact Delete"), MB_YESNO|MB_ICONEXCLAMATION) == IDYES) {
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact,0);
+ CallService(MS_DB_CONTACT_DELETE, hContact,0);
freeTree(((LPNMHDR)lParam)->hwndFrom,hContact);
TreeView_DeleteItem(((LPNMHDR)lParam)->hwndFrom,tvi.hItem);
}
}
else {
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact,0);
+ CallService(MS_DB_CONTACT_DELETE, hContact,0);
freeTree(((LPNMHDR)lParam)->hwndFrom,hContact);
TreeView_DeleteItem(((LPNMHDR)lParam)->hwndFrom,tvi.hItem);
}
diff --git a/plugins/FTPFileYM/src/dialog.cpp b/plugins/FTPFileYM/src/dialog.cpp index ccc015afcf..02c602f846 100644 --- a/plugins/FTPFileYM/src/dialog.cpp +++ b/plugins/FTPFileYM/src/dialog.cpp @@ -245,7 +245,7 @@ INT_PTR CALLBACK UploadDialog::UploadDlgProc(HWND hwndDlg, UINT msg, WPARAM wPar if (hContact != NULL)
{
RECT rc;
- HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0);
+ HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0);
GetWindowRect((HWND)lParam, &rc);
TrackPopupMenu(hMenu, 0, rc.left, rc.bottom, 0, hwndDlg, NULL);
DestroyMenu(hMenu);
diff --git a/plugins/FavContacts/src/favlist.h b/plugins/FavContacts/src/favlist.h index 0f16ef8fb6..b420f49c23 100644 --- a/plugins/FavContacts/src/favlist.h +++ b/plugins/FavContacts/src/favlist.h @@ -19,7 +19,7 @@ public: this->hContact = hContact;
this->bManual = bManual;
this->fRate = fRate;
- name = mir_tstrdup((TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
+ name = mir_tstrdup((TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR));
if (g_Options.bUseGroups && !db_get_ts(hContact, "CList", "Group", &dbv))
{
group = mir_tstrdup(dbv.ptszVal);
diff --git a/plugins/FavContacts/src/http_api.cpp b/plugins/FavContacts/src/http_api.cpp index 693ba4cd28..38705d3927 100644 --- a/plugins/FavContacts/src/http_api.cpp +++ b/plugins/FavContacts/src/http_api.cpp @@ -47,7 +47,7 @@ public: int hContact;
sscanf(s, "/fav/open/%d", &hContact);
if (CallService(MS_DB_CONTACT_IS, hContact, 0))
- CallServiceSync(MS_FAVCONTACTS_OPEN_CONTACT, (WPARAM)hContact, 0);
+ CallServiceSync(MS_FAVCONTACTS_OPEN_CONTACT, hContact, 0);
}
void SendList()
@@ -68,8 +68,8 @@ public: for (int i = 0; i < favList.getCount(); ++i)
{
MCONTACT hContact = favList[i]->getHandle();
- TCHAR *name = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
- AVATARCACHEENTRY *avatar = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ TCHAR *name = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
+ AVATARCACHEENTRY *avatar = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
int status = db_get_w(hContact, GetContactProto(hContact), "Status", ID_STATUS_OFFLINE);
Send("SetContact(");
diff --git a/plugins/FavContacts/src/main.cpp b/plugins/FavContacts/src/main.cpp index 3abb180e40..d51299e45c 100644 --- a/plugins/FavContacts/src/main.cpp +++ b/plugins/FavContacts/src/main.cpp @@ -250,7 +250,7 @@ int ProcessModulesLoaded(WPARAM wParam, LPARAM lParam) if (ServiceExists(MS_AV_GETAVATARBITMAP)) {
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
if (db_get_b(hContact, "FavContacts", "IsFavourite", 0))
- CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
}
return 0;
@@ -427,7 +427,7 @@ static BOOL sttMeasureItem_Contact(LPMEASUREITEMSTRUCT lpmis, Options *options) lpmis->itemHeight += sz.cy + 3;
}
- TCHAR *name = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *name = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
if (!options->bSysColors) SelectObject(hdc, g_Options.hfntName);
GetTextExtentPoint32(hdc, name, lstrlen(name), &sz);
@@ -442,7 +442,7 @@ static BOOL sttMeasureItem_Contact(LPMEASUREITEMSTRUCT lpmis, Options *options) if (options->bAvatars)
{
- AVATARCACHEENTRY *ace = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ AVATARCACHEENTRY *ace = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
if (ace && (ace != (AVATARCACHEENTRY *)CALLSERVICE_NOTFOUND))
{
int avatarWidth = lpmis->itemHeight;
@@ -582,7 +582,7 @@ static BOOL sttDrawItem_Contact(LPDRAWITEMSTRUCT lpdis, Options *options = NULL) char *proto = GetContactProto(hContact);
HIMAGELIST hIml = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
- int iIcon = CallService(MS_CLIST_GETCONTACTICON, (WPARAM)hContact, 0);
+ int iIcon = CallService(MS_CLIST_GETCONTACTICON, hContact, 0);
if (db_get_dw(hContact, proto, "IdleTS", 0)) {
ImageList_DrawDimmed(hIml, iIcon, hdcTemp,
@@ -604,7 +604,7 @@ static BOOL sttDrawItem_Contact(LPDRAWITEMSTRUCT lpdis, Options *options = NULL) }
if (options->bAvatars) {
- AVATARCACHEENTRY *ace = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ AVATARCACHEENTRY *ace = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
if (ace && (ace != (AVATARCACHEENTRY *)CALLSERVICE_NOTFOUND)) {
int avatarWidth = lpdis->rcItem.bottom - lpdis->rcItem.top;
if (ace->bmWidth < ace->bmHeight)
@@ -641,7 +641,7 @@ static BOOL sttDrawItem_Contact(LPDRAWITEMSTRUCT lpdis, Options *options = NULL) }
if (true) {
- TCHAR *name = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *name = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
if (!options->bSysColors) SelectObject(hdcTemp, g_Options.hfntName);
SetTextColor(hdcTemp, clLine1);
@@ -767,7 +767,7 @@ static LRESULT CALLBACK MenuHostWndProc(HWND hwnd, UINT message, WPARAM wParam, MCONTACT hContact = (MCONTACT)mii.dwItemData;
if (!CallService(MS_DB_CONTACT_IS, mii.dwItemData, 0)) return FALSE;
- HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0);
+ HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0);
POINT pt;
GetCursorPos(&pt);
@@ -873,7 +873,7 @@ int sttShowMenu(bool centered) DestroyMenu(hMenu);
if (hContact)
- CallService(MS_CLIST_CONTACTDOUBLECLICKED, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_CONTACTDOUBLECLICKED, hContact, 0);
return 0;
}
@@ -946,7 +946,7 @@ int ProcessSrmmIconClick(WPARAM hContact, LPARAM lParam) if (sicd->flags & MBCF_RIGHTBUTTON) {
BYTE fav = !db_get_b(hContact, "FavContacts", "IsFavourite", 0);
db_set_b(hContact, "FavContacts", "IsFavourite", fav);
- if (fav) CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ if (fav) CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
StatusIconData sid = { sizeof(sid) };
sid.szModule = "FavContacts";
@@ -1006,7 +1006,7 @@ static INT_PTR CALLBACK OptionsDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARA {
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
SendDlgItemMessage(hwnd, IDC_CLIST, CLM_SETCHECKMARK,
- SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0),
+ SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0),
db_get_b(hContact, "FavContacts", "IsFavourite", 0));
}
@@ -1128,10 +1128,10 @@ static INT_PTR CALLBACK OptionsDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARA for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
BYTE fav = SendDlgItemMessage(hwnd, IDC_CLIST, CLM_GETCHECKMARK,
- SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0), 0);
+ SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0), 0);
if (fav != db_get_b(hContact, "FavContacts", "IsFavourite", 0))
db_set_b(hContact, "FavContacts", "IsFavourite", fav);
- if (fav) CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ if (fav) CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
}
}
else if (((LPNMHDR)lParam)->idFrom == IDC_CLIST) {
@@ -1145,7 +1145,7 @@ static INT_PTR CALLBACK OptionsDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARA case CLN_NEWCONTACT:
iSelection = (int)((NMCLISTCONTROL *)lParam)->hItem;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- if (SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0) == iSelection) {
+ if (SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0) == iSelection) {
SendDlgItemMessage(hwnd, IDC_CLIST, CLM_SETCHECKMARK, iSelection,
db_get_b(hContact, "FavContacts", "IsFavourite", 0));
break;
@@ -1156,7 +1156,7 @@ static INT_PTR CALLBACK OptionsDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARA case CLN_CHECKCHANGED:
iSelection = (int)((NMCLISTCONTROL *)lParam)->hItem;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- if (SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0) == iSelection) {
+ if (SendDlgItemMessage(hwnd, IDC_CLIST, CLM_FINDCONTACT, hContact, 0) == iSelection) {
hSelectedContact = hContact;
RedrawWindow(GetDlgItem(hwnd, IDC_CANVAS), NULL, NULL, RDW_INVALIDATE);
}
diff --git a/plugins/FileAsMessage/src/dialog.cpp b/plugins/FileAsMessage/src/dialog.cpp index 9728ff95f2..f668fef130 100644 --- a/plugins/FileAsMessage/src/dialog.cpp +++ b/plugins/FileAsMessage/src/dialog.cpp @@ -73,7 +73,7 @@ static int CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM int indx = 0;
for(;;)
{
- if((lpcle = (CLISTEVENT*)CallService(MS_CLIST_GETEVENT, (WPARAM)hContact, indx)) == NULL)
+ if((lpcle = (CLISTEVENT*)CallService(MS_CLIST_GETEVENT, hContact, indx)) == NULL)
break;
if(lstrcmp(lpcle->pszService, SERVICE_NAME "/FERecvFile") == 0)
{
@@ -88,7 +88,7 @@ static int CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM case WM_COMMAND:
{
PUDeletePopup(hWnd);
- CallService(MS_CLIST_REMOVEEVENT, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_REMOVEEVENT, hContact, 0);
if(IsWindow(hDlg))
{
@@ -123,7 +123,7 @@ void MakePopupMsg(HWND hDlg, MCONTACT hContact, char *msg) POPUPDATA ppd = { 0 };
ppd.lchContact = hContact;
ppd.lchIcon = LoadIcon(hInst, MAKEINTRESOURCE(IDI_SMALLICON));
- lstrcpy(ppd.lpzContactName, (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, 0));
+ lstrcpy(ppd.lpzContactName, (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, 0));
lstrcpy(ppd.lpzText, msg);
ppd.colorBack = GetSysColor(COLOR_INFOBK);
ppd.colorText = GetSysColor(COLOR_INFOTEXT);
@@ -258,7 +258,7 @@ void FILEECHO::updateTitle() {
char newtitle[256], *contactName;
- contactName=(char*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,0);
+ contactName=(char*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,0);
if(iState == STATE_OPERATE && chunkCount != 0)
mir_snprintf(newtitle, sizeof(newtitle), "%d%% - %s: %s", chunkSent * 100 / chunkCount, Translate(szFEMode[inSend]), contactName);
else
@@ -445,7 +445,7 @@ void FILEECHO::incomeRequest(char *param) // param == &filename
char *p = strchr(param, '?');
if(p == NULL) return; *p++ = 0;
- CallService(MS_FILE_GETRECEIVEDFILESFOLDER, (WPARAM)hContact, (LPARAM)buf);
+ CallService(MS_FILE_GETRECEIVEDFILESFOLDER, hContact, (LPARAM)buf);
strncat(buf, param, sizeof(buf));
free(filename);
filename = strdup(buf);
@@ -565,7 +565,7 @@ void FILEECHO::onRecvTimer() if(db_get_b(NULL,"SRFile","AutoClose",0))
{
PostMessage(hDlg, WM_CLOSE, 0,0);
- CallService(MS_CLIST_REMOVEEVENT, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_REMOVEEVENT, hContact, 0);
}
SkinPlaySound("FileDone");
destroyTransfer();
diff --git a/plugins/FingerprintNG/src/options.cpp b/plugins/FingerprintNG/src/options.cpp index 74b62bacc9..137fc12836 100644 --- a/plugins/FingerprintNG/src/options.cpp +++ b/plugins/FingerprintNG/src/options.cpp @@ -104,7 +104,7 @@ static INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LP RegisterIcons();
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- OnExtraImageApply((WPARAM)hContact, 0);
+ OnExtraImageApply(hContact, 0);
}
break;
}
diff --git a/plugins/FloatingContacts/src/main.cpp b/plugins/FloatingContacts/src/main.cpp index 2bcc042554..416aa4857f 100644 --- a/plugins/FloatingContacts/src/main.cpp +++ b/plugins/FloatingContacts/src/main.cpp @@ -778,7 +778,7 @@ static void LoadContact( MCONTACT hContact ) DWORD dwPos = db_get_dw( hContact, MODULE, "ThumbsPos", (DWORD)-1);
if ( dwPos != -1) {
- TCHAR *ptName = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, (LPARAM)GCDNF_TCHAR);
+ TCHAR *ptName = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, (LPARAM)GCDNF_TCHAR);
if ( ptName != NULL ) {
int nX = DB_POS_GETX( dwPos );
int nY = DB_POS_GETY( dwPos );
diff --git a/plugins/FloatingContacts/src/thumbs.cpp b/plugins/FloatingContacts/src/thumbs.cpp index bc6b4888c7..a376d06838 100644 --- a/plugins/FloatingContacts/src/thumbs.cpp +++ b/plugins/FloatingContacts/src/thumbs.cpp @@ -315,7 +315,7 @@ void ThumbInfo::ResizeThumb() void ThumbInfo::RefreshContactIcon(int iIcon)
{
if (iIcon == 0xFFFFFFFF || ImageList_GetImageCount(himlMiranda) <= iIcon)
- this->iIcon = CallService(MS_CLIST_GETCONTACTICON, (WPARAM)hContact, 0);
+ this->iIcon = CallService(MS_CLIST_GETCONTACTICON, hContact, 0);
else
this->iIcon = iIcon;
@@ -689,7 +689,7 @@ void ThumbInfo::UpdateContent() void ThumbInfo::PopupMessageDialog( )
{
- CallService(MS_CLIST_CONTACTDOUBLECLICKED, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_CONTACTDOUBLECLICKED, hContact, 0);
}
void ThumbInfo::OnTimer(BYTE idTimer)
diff --git a/plugins/HTTPServer/src/GuiElements.cpp b/plugins/HTTPServer/src/GuiElements.cpp index 7b21ed1e8e..9e03f45127 100644 --- a/plugins/HTTPServer/src/GuiElements.cpp +++ b/plugins/HTTPServer/src/GuiElements.cpp @@ -1064,7 +1064,7 @@ static INT_PTR nShareNewFile(WPARAM hContact, LPARAM lParam) else
db_unset(hContact, MODULE, "LastUsedMask");
- SendLinkToUser((WPARAM)hContact, stNewShare.pszSrvPath);
+ SendLinkToUser(hContact, stNewShare.pszSrvPath);
return 0;
}
diff --git a/plugins/HistorySweeperLight/src/options.cpp b/plugins/HistorySweeperLight/src/options.cpp index fc6d6418e8..dac549cbf7 100644 --- a/plugins/HistorySweeperLight/src/options.cpp +++ b/plugins/HistorySweeperLight/src/options.cpp @@ -108,7 +108,7 @@ static void ShowAllContactIcons(HWND hwndList) MAKELPARAM(0, db_get_b(NULL, ModuleName, "SweepSHistory", 0)));
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
SendMessage(hwndList, CLM_SETEXTRAIMAGE, (WPARAM)hItem,
MAKELPARAM(0, db_get_b(hContact, ModuleName, "SweepHistory", 0)));
}
@@ -175,7 +175,7 @@ void SaveSettings(HWND hwndDlg) (BYTE)SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hSystemHistory, 0));
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
st = SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hItem, 0);
if ( st != 0 ) db_set_b(hContact, ModuleName, "SweepHistory", (BYTE)st);
diff --git a/plugins/IEView/src/HTMLBuilder.cpp b/plugins/IEView/src/HTMLBuilder.cpp index b8fc6eb740..827c6dac52 100644 --- a/plugins/IEView/src/HTMLBuilder.cpp +++ b/plugins/IEView/src/HTMLBuilder.cpp @@ -149,7 +149,7 @@ char* HTMLBuilder::getRealProto(MCONTACT hContact) char *szProto = mir_strdup(GetContactProto(hContact));
if (szProto != NULL && !strcmp(szProto, "MetaContacts")) {
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (hContact != NULL) {
mir_free(szProto);
szProto = mir_strdup(GetContactProto(hContact));
@@ -161,7 +161,7 @@ char* HTMLBuilder::getRealProto(MCONTACT hContact) char *HTMLBuilder::getRealProto(MCONTACT hContact, const char *szProto)
{
if (szProto != NULL && !strcmp(szProto, "MetaContacts")) {
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (hContact != NULL)
return mir_strdup(GetContactProto(hContact));
}
@@ -172,7 +172,7 @@ MCONTACT HTMLBuilder::getRealContact(MCONTACT hContact) {
char *szProto = GetContactProto(hContact);
if (szProto != NULL && !strcmp(szProto,"MetaContacts"))
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
return hContact;
}
diff --git a/plugins/IEView/src/TemplateHTMLBuilder.cpp b/plugins/IEView/src/TemplateHTMLBuilder.cpp index b58a6beddf..e533cefae4 100644 --- a/plugins/IEView/src/TemplateHTMLBuilder.cpp +++ b/plugins/IEView/src/TemplateHTMLBuilder.cpp @@ -51,7 +51,7 @@ char *TemplateHTMLBuilder::getAvatar(MCONTACT hContact, const char* szProto) if (hContact == NULL) {
ace = (struct avatarCacheEntry *)CallService(MS_AV_GETMYAVATAR, 0, (LPARAM)szProto);
} else {
- ace = (struct avatarCacheEntry *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ ace = (struct avatarCacheEntry *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
}
if (ace!=NULL) {
if ( ace->cbSize == sizeof(avatarCacheEntry))
diff --git a/plugins/IgnoreState/src/main.cpp b/plugins/IgnoreState/src/main.cpp index ebe32c0d36..505dcfe9bf 100644 --- a/plugins/IgnoreState/src/main.cpp +++ b/plugins/IgnoreState/src/main.cpp @@ -84,7 +84,7 @@ INT_PTR isIgnored(MCONTACT hContact, int type) int all = 0, filtered = 0;
if (type != IGNOREEVENT_ALL)
- return CallService(MS_IGNORE_ISIGNORED, (WPARAM)hContact, (LPARAM)type);
+ return CallService(MS_IGNORE_ISIGNORED, hContact, (LPARAM)type);
for (int i = 1; i < nII; i++)
if (isIgnored(hContact, ii[i].type))
diff --git a/plugins/KeyboardNotify/src/ignore.cpp b/plugins/KeyboardNotify/src/ignore.cpp index b119f4cdc3..299481793b 100644 --- a/plugins/KeyboardNotify/src/ignore.cpp +++ b/plugins/KeyboardNotify/src/ignore.cpp @@ -187,7 +187,7 @@ static void SetAllContactIcons(HWND hwndList) DWORD protoCaps;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
if(hItem && SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hItem, MAKELPARAM(IGNOREEVENT_MAX, 0)) == EMPTY_EXTRA_ICON) {
char *szProto = GetContactProto(hContact);
if(szProto == NULL)
@@ -311,7 +311,7 @@ INT_PTR CALLBACK DlgProcIgnoreOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPA case PSN_APPLY:
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_LIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_LIST, CLM_FINDCONTACT, hContact, 0);
if(hItem)
SaveItemMask(GetDlgItem(hwndDlg, IDC_LIST), hContact, hItem, "Mask1");
}
diff --git a/plugins/KeyboardNotify/src/main.cpp b/plugins/KeyboardNotify/src/main.cpp index ee716a6d73..690a33e4b6 100644 --- a/plugins/KeyboardNotify/src/main.cpp +++ b/plugins/KeyboardNotify/src/main.cpp @@ -261,7 +261,7 @@ BOOL metaCheckProtocol(char *szProto, MCONTACT hContact, WORD eventType) MCONTACT hSubContact=NULL;
if (szMetaProto && bMetaProtoEnabled && szProto && !strcmp(szMetaProto, szProto))
- if (hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0))
+ if (hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0))
szProto = GetContactProto(hSubContact);
return checkProtocol(szProto) && checkIgnore(hSubContact?hSubContact:hContact, eventType);
diff --git a/plugins/MenuItemEx/src/main.cpp b/plugins/MenuItemEx/src/main.cpp index a9bc2e5c66..cb04157a35 100644 --- a/plugins/MenuItemEx/src/main.cpp +++ b/plugins/MenuItemEx/src/main.cpp @@ -168,7 +168,7 @@ void RenameDbProto(MCONTACT hContact, MCONTACT hContactNew, char* oldName, char* dbces.lParam = (LPARAM)&settinglist;
settinglist.first = 0;
settinglist.last = 0;
- CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact,(LPARAM)&dbces);
+ CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact,(LPARAM)&dbces);
setting = settinglist.first;
while (setting) {
@@ -215,7 +215,7 @@ void ShowPopup(char* szText, TCHAR* tszText, MCONTACT hContact) ppd.lchIcon = LoadSkinnedIcon(SKINICON_OTHER_MIRANDA);
ppd.lchContact = hContact;
- _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR), MAX_CONTACTNAME - 1);
+ _tcsncpy(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR), MAX_CONTACTNAME - 1);
_tcsncpy(ppd.lptzText, text, MAX_SECONDLINE - 1);
ppd.iSeconds = -1;
@@ -227,7 +227,7 @@ BOOL DirectoryExists(MCONTACT hContact) {
int attr;
char path[MAX_PATH];
- CallService(MS_FILE_GETRECEIVEDFILESFOLDER, (WPARAM)hContact, (LPARAM)&path);
+ CallService(MS_FILE_GETRECEIVEDFILESFOLDER, hContact, (LPARAM)&path);
attr = GetFileAttributesA(path);
return (attr != -1) && (attr&FILE_ATTRIBUTE_DIRECTORY);
}
@@ -274,14 +274,14 @@ BOOL isMetaContact(MCONTACT hContact) MCONTACT getDefaultContact(MCONTACT hContact)
{
if (bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT, (WPARAM)hContact, 0);
+ return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT, hContact, 0);
return 0;
}
MCONTACT getMostOnline(MCONTACT hContact)
{
if (bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ return (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
return 0;
}
@@ -731,7 +731,7 @@ INT_PTR onChangeProto(WPARAM wparam, LPARAM lparam) if (CTRL_IS_PRESSED) {
hContactNew = hContact;
RenameDbProto(hContact, hContactNew, GetContactProto(hContact), (char*)lparam, 1);
- CallService(MS_PROTO_REMOVEFROMCONTACT, (WPARAM)hContact, (LPARAM)GetContactProto(hContact));
+ CallService(MS_PROTO_REMOVEFROMCONTACT, hContact, (LPARAM)GetContactProto(hContact));
CallService(MS_PROTO_ADDTOCONTACT, (WPARAM)hContactNew, lparam);
}
else {
@@ -755,7 +755,7 @@ INT_PTR onChangeProto(WPARAM wparam, LPARAM lparam) int isIgnored(MCONTACT hContact, int type)
{
if (type != IGNOREEVENT_ALL)
- return CallService(MS_IGNORE_ISIGNORED, (WPARAM)hContact, (LPARAM)type);
+ return CallService(MS_IGNORE_ISIGNORED, hContact, (LPARAM)type);
int i = 0, all = 0;
for (i = 1; i < SIZEOF(ii); i++)
@@ -963,7 +963,7 @@ static void TabsrmmButtonsModify(MCONTACT hContact) bbd.dwButtonID = 0;
bbd.pszModuleName = MODULENAME;
bbd.bbbFlags = BBSF_DISABLED | BBSF_HIDDEN;
- CallService(MS_BB_SETBUTTONSTATE, (WPARAM)hContact, (LPARAM)&bbd);
+ CallService(MS_BB_SETBUTTONSTATE, hContact, (LPARAM)&bbd);
}
}
diff --git a/plugins/MetaContacts/src/meta_menu.cpp b/plugins/MetaContacts/src/meta_menu.cpp index 853dc18394..0031b461ed 100644 --- a/plugins/MetaContacts/src/meta_menu.cpp +++ b/plugins/MetaContacts/src/meta_menu.cpp @@ -129,7 +129,7 @@ void Meta_RemoveContactNumber(MCONTACT hMeta, int number) // stop ignoring, if we were
if (options.suppress_status)
- CallService(MS_IGNORE_UNIGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_UNIGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
}
// each contact from 'number' upwards will be moved down one
@@ -229,7 +229,7 @@ INT_PTR Meta_Delete(WPARAM wParam,LPARAM lParam) // stop ignoring, if we were
if (options.suppress_status)
- CallService(MS_IGNORE_UNIGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_UNIGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
}
}
@@ -379,7 +379,7 @@ int Meta_ModifyMenu(WPARAM wParam, LPARAM lParam) mi.flags |= CMIM_FLAGS | CMIM_NAME | CMIM_ICON;
- int iconIndex = CallService(MS_CLIST_GETCONTACTICON, (WPARAM)hContact, 0);
+ int iconIndex = CallService(MS_CLIST_GETCONTACTICON, hContact, 0);
mi.hIcon = ImageList_GetIcon((HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0), iconIndex, 0);
Menu_ModifyItem(hMenuContact[i], &mi);
diff --git a/plugins/MetaContacts/src/meta_services.cpp b/plugins/MetaContacts/src/meta_services.cpp index c615a01b08..63578c17aa 100755 --- a/plugins/MetaContacts/src/meta_services.cpp +++ b/plugins/MetaContacts/src/meta_services.cpp @@ -793,7 +793,7 @@ int Meta_ContactDeleted(WPARAM wParam, LPARAM lParam) // stop ignoring, if we were
if (options.suppress_status)
- CallService(MS_IGNORE_UNIGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_UNIGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
}
}
return 0;
@@ -945,7 +945,7 @@ int Meta_ClistDoubleClicked(WPARAM wParam, LPARAM lParam) INT_PTR Meta_ClistMessageEventClicked(WPARAM wParam, LPARAM lParam)
{
MCONTACT hContact = ((CLISTEVENT *)lParam)->hContact;
- return Meta_ClistDoubleClicked((WPARAM)hContact, (LPARAM)((CLISTEVENT *)lParam)->hDbEvent);
+ return Meta_ClistDoubleClicked(hContact, (LPARAM)((CLISTEVENT *)lParam)->hDbEvent);
}
int NudgeRecieved(WPARAM wParam, LPARAM lParam)
@@ -1117,17 +1117,17 @@ INT_PTR Meta_ContactMenuFunc(WPARAM wParam, LPARAM lParam) CallService(MS_MSG_SENDMESSAGE, wParam, 0);
} else
// protocol does not support messaging - simulate double click
- CallService(MS_CLIST_CONTACTDOUBLECLICKED, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_CONTACTDOUBLECLICKED, hContact, 0);
} else
// protocol does not support messaging - simulate double click
- CallService(MS_CLIST_CONTACTDOUBLECLICKED, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_CONTACTDOUBLECLICKED, hContact, 0);
} else if (options.menu_function == FT_MENU) {
// show contact's context menu
CallFunctionAsync(sttMenuThread, (void*)hContact);
} else if (options.menu_function == FT_INFO) {
// show user info for subcontact
- CallService(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
+ CallService(MS_USERINFO_SHOWDIALOG, hContact, 0);
}
return 0;
diff --git a/plugins/MetaContacts/src/meta_utils.cpp b/plugins/MetaContacts/src/meta_utils.cpp index 4d83038cd3..6789e21352 100644 --- a/plugins/MetaContacts/src/meta_utils.cpp +++ b/plugins/MetaContacts/src/meta_utils.cpp @@ -719,7 +719,7 @@ int Meta_SetHandles(void) MessageBox(0, TranslateT("Subcontact contact number < 0 - deleting MetaContact"), nick_buffer, MB_OK | MB_ICONERROR);
//CallService(MS_DB_CONTACT_DELETE, (WPARMA)hContact, 0);
hNextContact = db_find_next(hContact);
- Meta_Delete((WPARAM)hContact, (LPARAM)1);
+ Meta_Delete(hContact, (LPARAM)1);
hContact = hNextContact;
continue;
//return 1;
@@ -758,7 +758,7 @@ int Meta_SetHandles(void) MessageBox(0, buff, nick_buffer, MB_OK | MB_ICONERROR);
hNextContact = db_find_next(hContact);
- Meta_Delete((WPARAM)hContact, (LPARAM)1);
+ Meta_Delete(hContact, (LPARAM)1);
hContact = hNextContact;
continue;
}
@@ -781,7 +781,7 @@ int Meta_SetHandles(void) // stop ignoring, if we were
if (options.suppress_status)
- CallService(MS_IGNORE_UNIGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_UNIGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
}
else {
@@ -809,7 +809,7 @@ int Meta_SetHandles(void) // problem
MessageBox(0, TranslateT("MetaContact number of contacts < 0 - deleting MetaContact"), nick_buffer, MB_OK | MB_ICONERROR);
hNextContact = db_find_next(hContact);
- Meta_Delete((WPARAM)hContact, (LPARAM)1);
+ Meta_Delete(hContact, (LPARAM)1);
hContact = hNextContact;
continue;
}
@@ -818,7 +818,7 @@ int Meta_SetHandles(void) // problem
MessageBox(0, TranslateT("MetaContact default contact number out of range - deleting MetaContact"), nick_buffer, MB_OK | MB_ICONERROR);
hNextContact = db_find_next(hContact);
- Meta_Delete((WPARAM)hContact, (LPARAM)1);
+ Meta_Delete(hContact, (LPARAM)1);
hContact = hNextContact;
continue;
}
@@ -841,7 +841,7 @@ int Meta_SetHandles(void) _tcscat(nick_buffer, _itot(meta_id, buffer2, 10));
MessageBox(0, TranslateT("MetaContact corrupted - the number of subcontacts is incorrect.\nDeleting MetaContact."), nick_buffer, MB_OK | MB_ICONERROR);
- Meta_Delete((WPARAM)hContact, (LPARAM)1);
+ Meta_Delete(hContact, (LPARAM)1);
hContact = hNextContact;
continue;
}
@@ -950,7 +950,7 @@ int Meta_HideLinkedContacts(void) { }
if (options.suppress_status)
- CallService(MS_IGNORE_IGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_IGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
}
hContact = db_find_next(hContact);
@@ -1122,9 +1122,9 @@ int Meta_SuppressStatus(BOOL suppress) if (db_get_dw(hContact, META_PROTO, META_LINK,(DWORD)-1)!=(DWORD)-1) {
// is a subcontact
if (suppress)
- CallService(MS_IGNORE_IGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_IGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
else
- CallService(MS_IGNORE_UNIGNORE, (WPARAM)hContact, (WPARAM)IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_UNIGNORE, hContact, (WPARAM)IGNOREEVENT_USERONLINE);
}
}
diff --git a/plugins/MirFox/src/MirandaOptions.cpp b/plugins/MirFox/src/MirandaOptions.cpp index 9492ab98a0..b8f7acda2f 100644 --- a/plugins/MirFox/src/MirandaOptions.cpp +++ b/plugins/MirFox/src/MirandaOptions.cpp @@ -170,7 +170,7 @@ static void setListContactIcons(HWND hwndList){ for (mirandaContactsIter = mirandaContactsPtr->begin(); mirandaContactsIter != mirandaContactsPtr->end(); mirandaContactsIter++){
MCONTACT hContact = mirandaContactsIter->contactHandle;
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
if(hItem) {
//if icon on 0th extracolumn is not set
if(SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hItem, MAKELPARAM(0,0)) == 0xFF){
@@ -486,7 +486,7 @@ INT_PTR CALLBACK DlgProcOpts_Tab2(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)){
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC2_CONTACTS_LIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC2_CONTACTS_LIST, CLM_FINDCONTACT, hContact, 0);
if(hItem) {
int iImage = SendDlgItemMessage(hwndDlg, IDC2_CONTACTS_LIST, CLM_GETEXTRAIMAGE, (WPARAM)hItem, MAKELPARAM(0,0));
diff --git a/plugins/MirFox/src/MirandaUtils.cpp b/plugins/MirFox/src/MirandaUtils.cpp index 3681c30251..24307322eb 100644 --- a/plugins/MirFox/src/MirandaUtils.cpp +++ b/plugins/MirFox/src/MirandaUtils.cpp @@ -148,7 +148,7 @@ void MirandaUtils::sendMessage(ActionThreadArgStruct* args, MFENUM_SEND_MESSAGE_ //TODO - metacontacts support - C:\MIRANDA\SOURCES\PLUGINS\popup_trunk\src\popup_wnd2.cpp : 1083
// //check for MetaContact and get szProto from subcontact
// if(strcmp(targetHandleSzProto, gszMetaProto)==0) {
- // HANDLE hSubContact = (HANDLE)CallService(MS_MC_GETDEFAULTCONTACT, (WPARAM)hContact, 0);
+ // HANDLE hSubContact = (HANDLE)CallService(MS_MC_GETDEFAULTCONTACT, hContact, 0);
// if(!hSubContact) return FALSE;
// targetHandleSzProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM) hSubContact, 0);
// }
diff --git a/plugins/MirOTR/MirOTR/src/dbfilter.cpp b/plugins/MirOTR/MirOTR/src/dbfilter.cpp index 674a4965de..c3ebb7f95a 100644 --- a/plugins/MirOTR/MirOTR/src/dbfilter.cpp +++ b/plugins/MirOTR/MirOTR/src/dbfilter.cpp @@ -62,7 +62,7 @@ int OnDatabaseEventPreAdd(WPARAM hContact, LPARAM lParam) return 0;
if(g_metaproto && strcmp(proto, g_metaproto) == 0) {
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (!hContact) return 0;
proto = contact_get_proto(hContact);
if (!proto ) return 0;
@@ -196,7 +196,7 @@ int OnDatabaseEventPreAdd(WPARAM hContact, LPARAM lParam) if (!db_event_get((HANDLE)lParam, &info)) {
if(info.eventType == EVENTTYPE_MESSAGE) {
MCONTACT hSub;
- if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hSub;
ConnContext *context = otrl_context_find_miranda(otr_user_state, hContact);
@@ -252,10 +252,10 @@ int WindowEvent(WPARAM wParam, LPARAM lParam) { if(mwd->uType != MSG_WINDOW_EVT_OPEN) return 0;
MCONTACT hContact = mwd->hContact, hTemp;
- if(options.bHaveMetaContacts && (hTemp = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(options.bHaveMetaContacts && (hTemp = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hTemp;
- if (!CallService(MS_PROTO_ISPROTOONCONTACT, (WPARAM)hContact, (LPARAM)MODULENAME))
+ if (!CallService(MS_PROTO_ISPROTOONCONTACT, hContact, (LPARAM)MODULENAME))
return 0;
lib_cs_lock();
@@ -319,7 +319,7 @@ int OnContactSettingChanged(WPARAM hContact, LPARAM lParam) // Terminate sessions with all contacts of that proto
StatusModeChange((WPARAM) ID_STATUS_OFFLINE, (LPARAM)cws->szModule);
return 0;
- }else if(CallService(MS_PROTO_ISPROTOONCONTACT, (WPARAM)hContact, (LPARAM)MODULENAME)) {
+ }else if(CallService(MS_PROTO_ISPROTOONCONTACT, hContact, (LPARAM)MODULENAME)) {
// only care about contacts to which this filter is attached
FinishSession(hContact);
}
diff --git a/plugins/MirOTR/MirOTR/src/dllmain.cpp b/plugins/MirOTR/MirOTR/src/dllmain.cpp index 22973c7676..232751e146 100644 --- a/plugins/MirOTR/MirOTR/src/dllmain.cpp +++ b/plugins/MirOTR/MirOTR/src/dllmain.cpp @@ -89,7 +89,7 @@ extern "C" __declspec(dllexport) int Load(void) // remove us as a filter to all contacts - fix filter type problem
if(db_get_b(0, MODULENAME, "FilterOrderFix", 0) != 2) {
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- CallService(MS_PROTO_REMOVEFROMCONTACT, (WPARAM)hContact, (LPARAM)MODULENAME);
+ CallService(MS_PROTO_REMOVEFROMCONTACT, hContact, (LPARAM)MODULENAME);
db_set_b(0, MODULENAME, "FilterOrderFix", 2);
}
diff --git a/plugins/MirOTR/MirOTR/src/mirotrmenu.cpp b/plugins/MirOTR/MirOTR/src/mirotrmenu.cpp index 2714a21e4f..513326712f 100644 --- a/plugins/MirOTR/MirOTR/src/mirotrmenu.cpp +++ b/plugins/MirOTR/MirOTR/src/mirotrmenu.cpp @@ -86,7 +86,7 @@ INT_PTR MirOTRMenuCheckService(WPARAM wParam,LPARAM) return TRUE;
MCONTACT hContact = (MCONTACT)pcpp->wParam, hSub;
- if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hSub;
TrustLevel level = ( TrustLevel )otr_context_get_trust(otrl_context_find_miranda(otr_user_state, hContact));
@@ -177,7 +177,7 @@ LRESULT CALLBACK PopupMenuWndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM }
void ShowOTRMenu(MCONTACT hContact, POINT pt){
- HMENU menu = (HMENU) CallService(MS_MIROTR_MENUBUILDMIROTR, (WPARAM)hContact, 0);
+ HMENU menu = (HMENU) CallService(MS_MIROTR_MENUBUILDMIROTR, hContact, 0);
SetWindowLongPtr(hDummyPaintWin, GWLP_USERDATA, (LONG_PTR)hContact);
TrackPopupMenu(menu, 0, pt.x, pt.y, 0, hDummyPaintWin, 0);
DestroyMenu(menu);
diff --git a/plugins/MirOTR/MirOTR/src/options.cpp b/plugins/MirOTR/MirOTR/src/options.cpp index f090d9b474..613178905b 100644 --- a/plugins/MirOTR/MirOTR/src/options.cpp +++ b/plugins/MirOTR/MirOTR/src/options.cpp @@ -559,7 +559,7 @@ static INT_PTR CALLBACK DlgProcMirOTROptsContacts(HWND hwndDlg, UINT msg, WPARAM TCHAR *proto_t;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
proto = contact_get_proto(hContact);
- if(proto && db_get_b(hContact, proto, "ChatRoom", 0) == 0 && CallService(MS_PROTO_ISPROTOONCONTACT, (WPARAM)hContact, (LPARAM)MODULENAME) // ignore chatrooms
+ if(proto && db_get_b(hContact, proto, "ChatRoom", 0) == 0 && CallService(MS_PROTO_ISPROTOONCONTACT, hContact, (LPARAM)MODULENAME) // ignore chatrooms
&& (g_metaproto == 0 || strcmp(proto, g_metaproto) != 0)) // and MetaContacts
{
lvI.iItem = 0;
diff --git a/plugins/MirOTR/MirOTR/src/svcs_menu.cpp b/plugins/MirOTR/MirOTR/src/svcs_menu.cpp index 5240337872..0db55124ea 100644 --- a/plugins/MirOTR/MirOTR/src/svcs_menu.cpp +++ b/plugins/MirOTR/MirOTR/src/svcs_menu.cpp @@ -26,10 +26,10 @@ int StartOTR(MCONTACT hContact) { INT_PTR SVC_StartOTR(WPARAM hContact, LPARAM lParam)
{
MCONTACT hSub;
- if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hSub;
- if ( options.bHaveSecureIM && CallService("SecureIM/IsContactSecured", (WPARAM)hContact, 0) != 0 ) {
+ if ( options.bHaveSecureIM && CallService("SecureIM/IsContactSecured", hContact, 0) != 0 ) {
TCHAR msg[512];
mir_sntprintf(msg, 512, TranslateT(LANG_OTR_SECUREIM_STARTED), contact_get_nameT(hContact));
ShowError(msg);
@@ -46,10 +46,10 @@ INT_PTR SVC_StartOTR(WPARAM hContact, LPARAM lParam) INT_PTR SVC_RefreshOTR(WPARAM hContact, LPARAM lParam)
{
MCONTACT hSub;
- if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hSub;
- if ( options.bHaveSecureIM && CallService("SecureIM/IsContactSecured", (WPARAM)hContact, 0) != 0 ) {
+ if ( options.bHaveSecureIM && CallService("SecureIM/IsContactSecured", hContact, 0) != 0 ) {
TCHAR msg[512];
mir_sntprintf(msg, 512, TranslateT(LANG_OTR_SECUREIM_STARTED), contact_get_nameT(hContact));
ShowError(msg);
@@ -69,7 +69,7 @@ INT_PTR SVC_RefreshOTR(WPARAM hContact, LPARAM lParam) int otr_disconnect_contact(MCONTACT hContact)
{
MCONTACT hSub;
- if(ServiceExists(MS_MC_GETMOSTONLINECONTACT) && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(ServiceExists(MS_MC_GETMOSTONLINECONTACT) && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hSub;
const char *proto = contact_get_proto(hContact);
@@ -100,7 +100,7 @@ INT_PTR SVC_StopOTR(WPARAM hContact, LPARAM lParam) INT_PTR SVC_VerifyOTR(WPARAM hContact, LPARAM lParam)
{
MCONTACT hSub;
- if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0)) != 0)
+ if(options.bHaveMetaContacts && (hSub = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0)) != 0)
hContact = hSub;
ConnContext *context = otrl_context_find_miranda(otr_user_state, hContact);
@@ -166,7 +166,7 @@ hide_all: if(proto && g_metaproto && strcmp(proto, g_metaproto) == 0) {
// make menu act as per most online subcontact
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (!hContact)
goto hide_all;
proto = contact_get_proto(hContact);
diff --git a/plugins/MirOTR/MirOTR/src/svcs_srmm.cpp b/plugins/MirOTR/MirOTR/src/svcs_srmm.cpp index e07473eb15..fcc4b5e85a 100644 --- a/plugins/MirOTR/MirOTR/src/svcs_srmm.cpp +++ b/plugins/MirOTR/MirOTR/src/svcs_srmm.cpp @@ -66,11 +66,11 @@ void SetEncryptionStatus(MCONTACT hContact, TrustLevel level) Srmm_ModifyIcon(hContact, &sid);
Srmm_ModifyIcon(hContact, &sid2);
- if (options.bHaveButtonsBar) CallService(MS_BB_SETBUTTONSTATE, (WPARAM)hContact, (LPARAM)&button);
+ if (options.bHaveButtonsBar) CallService(MS_BB_SETBUTTONSTATE, hContact, (LPARAM)&button);
db_set_dw(hContact, MODULENAME, "TrustLevel", level);
if (!chat_room && options.bHaveMetaContacts) {
- MCONTACT hMeta = (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ MCONTACT hMeta = (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0);
MCONTACT hMostOnline = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hMeta, 0);
if(hMeta && hContact == hMostOnline)
SetEncryptionStatus(hMeta, level);
diff --git a/plugins/MirOTR/MirOTR/src/utils.cpp b/plugins/MirOTR/MirOTR/src/utils.cpp index 6ed4c351f9..03fdbcac7a 100644 --- a/plugins/MirOTR/MirOTR/src/utils.cpp +++ b/plugins/MirOTR/MirOTR/src/utils.cpp @@ -136,14 +136,14 @@ char* contact_get_id(MCONTACT hContact, bool bNameOnError) { }
}
if (!pszUniqueID && bNameOnError) {
- char *name = (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, 0);
+ char *name = (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, 0);
if (name) pszUniqueID = mir_strdup(name);
}
return pszUniqueID;
}
__inline const TCHAR* contact_get_nameT(MCONTACT hContact) {
- return (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ return (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
}
__inline const char* contact_get_proto(MCONTACT hContact) {
@@ -152,7 +152,7 @@ __inline const char* contact_get_proto(MCONTACT hContact) { }
__inline const char* contact_get_account(MCONTACT hContact) {
- char *uacc = (char *)CallService(MS_PROTO_GETCONTACTBASEACCOUNT, (WPARAM)hContact, 0);
+ char *uacc = (char *)CallService(MS_PROTO_GETCONTACTBASEACCOUNT, hContact, 0);
return uacc;
}
@@ -364,7 +364,7 @@ bool GetEncryptionStatus(MCONTACT hContact) { if (!chat_room) {
if (options.bHaveMetaContacts) {
- HANDLE hMeta = (HANDLE)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ HANDLE hMeta = (HANDLE)CallService(MS_MC_GETMETACONTACT, hContact, 0);
if(hMeta && hContact == (HANDLE)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hMeta, 0)) {
//strcat(dbg_msg, "\nrecursing for meta");
return GetEncryptionStatus(hMeta);
diff --git a/plugins/MirandaG15/src/CAppletManager.cpp b/plugins/MirandaG15/src/CAppletManager.cpp index b8cebd541e..483c31652a 100644 --- a/plugins/MirandaG15/src/CAppletManager.cpp +++ b/plugins/MirandaG15/src/CAppletManager.cpp @@ -464,7 +464,7 @@ bool CAppletManager::ActivateChatScreen(MCONTACT hContact) tstring CAppletManager::GetContactDisplayname(MCONTACT hContact,bool bShortened)
{
if(!bShortened || !CConfig::GetBoolSetting(NOTIFY_NICKCUTOFF))
- return (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ return (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
tstring strNick = GetContactDisplayname(hContact,false);
if(strNick.length() > (tstring::size_type)CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET))
@@ -791,7 +791,7 @@ bool CAppletManager::IsSubContact(MCONTACT hContact) return false;
bool bIsSubcontact = db_get_b(hContact,"MetaContacts","IsSubcontact",0);
return bIsSubcontact;
- // HANDLE hMetaContact = (HANDLE)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, NULL);
+ // HANDLE hMetaContact = (HANDLE)CallService(MS_MC_GETMETACONTACT, hContact, NULL);
// return hMetaContact != NULL;
}
@@ -815,7 +815,7 @@ void CAppletManager::SendTypingNotification(MCONTACT hContact,bool bEnable) if (!db_get_b(hContact, "SRMsg", "SupportTyping", db_get_b(NULL, "SRMsg", "DefaultTyping", 1)))
return;
- char *szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0);
+ char *szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, hContact, 0);
if (!szProto)
return;
@@ -849,7 +849,7 @@ HANDLE CAppletManager::SendMessageToContact(MCONTACT hContact,tstring strMessage pJob->dwTimestamp = GetTickCount();
pJob->hContact = hContact;
- char *szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0);
+ char *szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, hContact, 0);
tstring strProto = toTstring(szProto);
CIRCConnection *pIRCCon = CAppletManager::GetInstance()->GetIRCConnection(strProto);
@@ -945,7 +945,7 @@ bool CAppletManager::IsMessageWindowOpen(MCONTACT hContact) void CAppletManager::MarkMessageAsRead(MCONTACT hContact,HANDLE hEvent)
{
db_event_markRead(hContact, hEvent);
- CallService(MS_CLIST_REMOVEEVENT, (WPARAM)hContact, (LPARAM)hEvent);
+ CallService(MS_CLIST_REMOVEEVENT, hContact, (LPARAM)hEvent);
}
//************************************************************************
@@ -1216,7 +1216,7 @@ void CAppletManager::DeleteIRCHistory(MCONTACT hContact) //************************************************************************
CIRCHistory *CAppletManager::CreateIRCHistory(MCONTACT hContact,tstring strChannel)
{
- char *szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0);
+ char *szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, hContact, 0);
if(!szProto)
return NULL;
diff --git a/plugins/MirandaG15/src/CChatScreen.cpp b/plugins/MirandaG15/src/CChatScreen.cpp index 4eef6df9b1..6fb7cd99e9 100644 --- a/plugins/MirandaG15/src/CChatScreen.cpp +++ b/plugins/MirandaG15/src/CChatScreen.cpp @@ -233,7 +233,7 @@ bool CChatScreen::SetContact(MCONTACT hContact) }
// Check if the contact is valid
- char *szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)hContact, 0);
+ char *szProto = (char *) CallService(MS_PROTO_GETCONTACTBASEPROTO, hContact, 0);
m_strProto = toTstring(szProto);
CIRCConnection *pIRCCon = CAppletManager::GetInstance()->GetIRCConnection(m_strProto);
diff --git a/plugins/MirandaG15/src/CContactList.cpp b/plugins/MirandaG15/src/CContactList.cpp index c22859cce5..046582e2e0 100644 --- a/plugins/MirandaG15/src/CContactList.cpp +++ b/plugins/MirandaG15/src/CContactList.cpp @@ -83,7 +83,7 @@ tstring CContactList::GetContactGroupPath(MCONTACT hContact) tstring strGroup = _T("");
if(db_get_b(0, "MetaContacts", "Enabled", 1) && CAppletManager::IsSubContact(hContact))
{
- MCONTACT hMetaContact = (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, NULL);
+ MCONTACT hMetaContact = (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, NULL);
if(CConfig::GetBoolSetting(CLIST_USEGROUPS))
strGroup = CAppletManager::GetContactGroup(hMetaContact);
@@ -150,17 +150,17 @@ void CContactList::AddContact(MCONTACT hContact) pGroup->sort(CContactList::CompareEntries);
// check that all subcontacts exist
- int numContacts = CallService(MS_MC_GETNUMCONTACTS,(WPARAM)hContact,0);
+ int numContacts = CallService(MS_MC_GETNUMCONTACTS,hContact,0);
MCONTACT hSubContact = NULL;
for(int i=0;i<numContacts;i++) {
- hSubContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, (WPARAM)hContact, (LPARAM)i);
+ hSubContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, hContact, (LPARAM)i);
RemoveContact(hSubContact);
AddContact(hSubContact);
}
return;
}
else if(CAppletManager::IsSubContact(hContact)) {
- MCONTACT hMetaContact = (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ MCONTACT hMetaContact = (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0);
// check that the metacontact exists
if(!FindContact(hMetaContact)) {
AddContact(hMetaContact);
@@ -279,9 +279,9 @@ void CContactList::RemoveContact(MCONTACT hContact) { else {
pGroup->RemoveGroup(((CListContainer<CContactListEntry*,CContactListGroup*>*)pContactEntry)->GetGroupData());
// Reenumerate all subcontacts (maybe MetaContacts was disabled
- int numContacts = CallService(MS_MC_GETNUMCONTACTS,(WPARAM)hContact,0);
+ int numContacts = CallService(MS_MC_GETNUMCONTACTS,hContact,0);
for(int i=0;i<numContacts;i++) {
- MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT,(WPARAM)hContact, (LPARAM)i);
+ MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT,hContact, (LPARAM)i);
if(!FindContact(hSubContact))
AddContact(hSubContact);
}
diff --git a/plugins/MobileState/src/main.cpp b/plugins/MobileState/src/main.cpp index 9130103774..afc61158f9 100644 --- a/plugins/MobileState/src/main.cpp +++ b/plugins/MobileState/src/main.cpp @@ -103,7 +103,7 @@ int onModulesLoaded(WPARAM wParam,LPARAM lParam) // Set initial value for all contacts
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- ExtraIconsApply((WPARAM)hContact, 1);
+ ExtraIconsApply(hContact, 1);
return 0;
}
diff --git a/plugins/ModernOpt/src/mopt_ignore.cpp b/plugins/ModernOpt/src/mopt_ignore.cpp index 77437f1b74..69014d0acc 100644 --- a/plugins/ModernOpt/src/mopt_ignore.cpp +++ b/plugins/ModernOpt/src/mopt_ignore.cpp @@ -50,7 +50,7 @@ static void ResetListOptions(HWND hwndList) static void SetAllContactIcons(HWND hwndList, int count)
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- DWORD hItem = SendMessage(hwndList,CLM_FINDCONTACT,(WPARAM)hContact,0);
+ DWORD hItem = SendMessage(hwndList,CLM_FINDCONTACT,hContact,0);
for (int i = 0; i < count; ++i)
SendMessage(hwndList,CLM_SETEXTRAIMAGE,hItem,MAKELPARAM(i, i+1));
if (!db_get_b(hContact,"CList","Hidden",0))
diff --git a/plugins/Msg_Export/src/utils.cpp b/plugins/Msg_Export/src/utils.cpp index cfe4c7d70b..0dc51f7af1 100755 --- a/plugins/Msg_Export/src/utils.cpp +++ b/plugins/Msg_Export/src/utils.cpp @@ -257,7 +257,7 @@ void DisplayLastError(const TCHAR *pszError) const TCHAR* NickFromHandle(MCONTACT hContact)
{
- const TCHAR *psz = (const TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ const TCHAR *psz = (const TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
if (psz )
return psz;
return pszNickError;
diff --git a/plugins/NewEventNotify/src/main.cpp b/plugins/NewEventNotify/src/main.cpp index 440c997460..a100978f0a 100644 --- a/plugins/NewEventNotify/src/main.cpp +++ b/plugins/NewEventNotify/src/main.cpp @@ -71,7 +71,7 @@ int HookedNewEvent(WPARAM hContact, LPARAM lParam) db_event_get((HANDLE)lParam, &dbe);
//do not show popups for sub-contacts
- if (hContact && ServiceExists(MS_MC_GETMETACONTACT) && CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0))
+ if (hContact && ServiceExists(MS_MC_GETMETACONTACT) && CallService(MS_MC_GETMETACONTACT, hContact, 0))
return 0;
//custom database event types
diff --git a/plugins/NewEventNotify/src/popup.cpp b/plugins/NewEventNotify/src/popup.cpp index b12587f750..3f1ce3646a 100644 --- a/plugins/NewEventNotify/src/popup.cpp +++ b/plugins/NewEventNotify/src/popup.cpp @@ -463,7 +463,7 @@ int PopupShow(PLUGIN_OPTIONS* pluginOptions, MCONTACT hContact, HANDLE hEvent, U _tcsncpy(pudw.lptzText, TranslateTS(sampleEvent), MAX_SECONDLINE);
}
else { // get the needed event data
- _tcsncpy(pudw.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR), MAX_CONTACTNAME);
+ _tcsncpy(pudw.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR), MAX_CONTACTNAME);
_tcsncpy(pudw.lptzText, ptrT(GetEventPreview(&dbe)), MAX_SECONDLINE);
}
diff --git a/plugins/NewXstatusNotify/src/indsnd.cpp b/plugins/NewXstatusNotify/src/indsnd.cpp index b4c0330129..f64b225988 100644 --- a/plugins/NewXstatusNotify/src/indsnd.cpp +++ b/plugins/NewXstatusNotify/src/indsnd.cpp @@ -332,7 +332,7 @@ void SetAllContactsIcons(HWND hwndList) BYTE EnableSounds, EnablePopups, EnableXStatus, EnableLogging;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
if (hItem) {
char *szProto = GetContactProto(hContact);
if (szProto) {
@@ -571,7 +571,7 @@ INT_PTR CALLBACK DlgProcFiltering(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM switch (((LPNMHDR)lParam)->code) {
case PSN_APPLY:
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hList, CLM_FINDCONTACT, hContact, 0);
if (hItem) {
if (GetExtraImage(hList, hItem, EXTRA_IMAGE_SOUND) == EXTRA_IMAGE_SOUND)
db_unset(hContact, MODULE, "EnableSounds");
diff --git a/plugins/NewXstatusNotify/src/main.cpp b/plugins/NewXstatusNotify/src/main.cpp index 30e5927735..6c9f024712 100644 --- a/plugins/NewXstatusNotify/src/main.cpp +++ b/plugins/NewXstatusNotify/src/main.cpp @@ -434,11 +434,11 @@ int ProcessStatus(DBCONTACTWRITESETTING *cws, MCONTACT hContact) db_set_w(hContact, "UserOnline", "OldStatus", newStatus);
//If *Miranda* ignores the UserOnline event, exit!
- if (CallService(MS_IGNORE_ISIGNORED, (WPARAM)hContact, IGNOREEVENT_USERONLINE))
+ if (CallService(MS_IGNORE_ISIGNORED, hContact, IGNOREEVENT_USERONLINE))
return 0;
//If we get here, we have to notify the Hooks.
- NotifyEventHooks(hHookContactStatusChanged, (WPARAM)hContact, (LPARAM)MAKELPARAM(oldStatus, newStatus));
+ NotifyEventHooks(hHookContactStatusChanged, hContact, (LPARAM)MAKELPARAM(oldStatus, newStatus));
return 1;
}
else if ( !strcmp(cws->szModule, "CList") && !strcmp(cws->szSetting, "StatusMsg")) {
@@ -619,7 +619,7 @@ void ShowStatusChangePopup(MCONTACT hContact, char *szProto, WORD oldStatus, WOR POPUPDATAT ppd = {0};
ppd.lchContact = hContact;
ppd.lchIcon = LoadSkinnedProtoIcon(szProto, newStatus);
- _tcsncpy(ppd.lptzContactName, (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GSMDF_TCHAR), MAX_CONTACTNAME);
+ _tcsncpy(ppd.lptzContactName, (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GSMDF_TCHAR), MAX_CONTACTNAME);
if (opt.ShowGroup) { //add group name to popup title
DBVARIANT dbv;
@@ -698,7 +698,7 @@ void BlinkIcon(MCONTACT hContact, char* szProto, WORD status) cle.pszService = "UserOnline/Description";
cle.ptszTooltip = stzTooltip;
- TCHAR *hlpName = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *hlpName = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
mir_sntprintf(stzTooltip, SIZEOF(stzTooltip), TranslateT("%s is now %s"), hlpName, StatusList[Index(status)].lpzStandardText);
CallService(MS_CLIST_ADDEVENT, 0, (LPARAM)&cle);
}
@@ -776,7 +776,7 @@ int ContactStatusChanged(WPARAM hContact, LPARAM lParam) }
if (strcmp(szProto, szMetaModuleName) == 0) { //this contact is Meta
- MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
hlpProto = GetContactProto(hSubContact);
if (hlpProto == NULL)
return 0;
@@ -842,7 +842,7 @@ int ContactStatusChanged(WPARAM hContact, LPARAM lParam) TCHAR stzDate[MAX_STATUSTEXT], stzTime[MAX_STATUSTEXT];
TCHAR stzText[1024];
- _tcscpy(stzName, (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
+ _tcscpy(stzName, (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR));
_tcsncpy(stzStatus, StatusList[Index(newStatus)].lpzStandardText, MAX_STATUSTEXT);
_tcsncpy(stzOldStatus, StatusList[Index(oldStatus)].lpzStandardText, MAX_STATUSTEXT);
GetTimeFormat(LOCALE_USER_DEFAULT, 0, NULL,_T("HH':'mm"), stzTime, SIZEOF(stzTime));
diff --git a/plugins/NewXstatusNotify/src/popup.cpp b/plugins/NewXstatusNotify/src/popup.cpp index 8d36c769ab..d691d12118 100644 --- a/plugins/NewXstatusNotify/src/popup.cpp +++ b/plugins/NewXstatusNotify/src/popup.cpp @@ -80,13 +80,13 @@ void PopupAction(HWND hWnd, BYTE action) if (hContact && hContact != INVALID_CONTACT_ID) {
switch (action) {
case PCA_OPENMESSAGEWND:
- CallServiceSync(MS_MSG_SENDMESSAGET, (WPARAM)hContact, 0);
+ CallServiceSync(MS_MSG_SENDMESSAGET, hContact, 0);
break;
case PCA_OPENMENU:
{
POINT pt = {0};
- HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0);
+ HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0);
GetCursorPos(&pt);
TrackPopupMenu(hMenu, 0, pt.x, pt.y, 0, hWnd, NULL);
DestroyMenu(hMenu);
@@ -94,11 +94,11 @@ void PopupAction(HWND hWnd, BYTE action) return;
case PCA_OPENDETAILS:
- CallServiceSync(MS_USERINFO_SHOWDIALOG, (WPARAM)hContact, 0);
+ CallServiceSync(MS_USERINFO_SHOWDIALOG, hContact, 0);
break;
case PCA_OPENHISTORY:
- CallServiceSync(MS_HISTORY_SHOWCONTACTHISTORY, (WPARAM)hContact, 0);
+ CallServiceSync(MS_HISTORY_SHOWCONTACTHISTORY, hContact, 0);
break;
case PCA_CLOSEPOPUP:
diff --git a/plugins/New_GPG/src/main.cpp b/plugins/New_GPG/src/main.cpp index c145fb41b0..5117e2b418 100755 --- a/plugins/New_GPG/src/main.cpp +++ b/plugins/New_GPG/src/main.cpp @@ -1299,7 +1299,7 @@ static INT_PTR CALLBACK DlgProcNewKeyDialog(HWND hwndDlg, UINT msg, WPARAM wPara mir_free(tmp); tmp = new TCHAR [256]; _tcscpy(tmp, TranslateT("Received key from ")); - _tcscat(tmp, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, (LPARAM)GCDNF_TCHAR)); + _tcscat(tmp, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, (LPARAM)GCDNF_TCHAR)); SetDlgItemText(hwndDlg, IDC_KEY_FROM, tmp); delete [] tmp; } diff --git a/plugins/New_GPG/src/messages.cpp b/plugins/New_GPG/src/messages.cpp index 70ce62ddf5..af59cbe729 100755 --- a/plugins/New_GPG/src/messages.cpp +++ b/plugins/New_GPG/src/messages.cpp @@ -38,7 +38,7 @@ void RecvMsgSvc_func(MCONTACT hContact, std::wstring str, char *msg, DWORD flags if(!isContactSecured(hContact)) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: received encrypted message from: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" with turned off encryption"); + debuglog<<std::string(time_str()+": info: received encrypted message from: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" with turned off encryption"); if(MessageBox(0, TranslateT("We received encrypted message from contact with encryption turned off.\nDo you want to turn on encryption for this contact?"), TranslateT("Warning"), MB_YESNO) == IDYES) { if(!isContactHaveKey(hContact)) @@ -70,7 +70,7 @@ void RecvMsgSvc_func(MCONTACT hContact, std::wstring str, char *msg, DWORD flags } else if(bDebugLog) { - debuglog<<std::string(time_str()+": info: received encrypted message from: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info: received encrypted message from: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); } boost::algorithm::erase_all(str, "\r"); s2 += _tcslen(_T("-----END PGP MESSAGE-----")); @@ -104,13 +104,13 @@ void RecvMsgSvc_func(MCONTACT hContact, std::wstring str, char *msg, DWORD flags dbsetting += "_Password"; pass = UniGetContactSettingUtf(NULL, szGPGModuleName, dbsetting.c_str(), _T("")); if(pass[0] && bDebugLog) - debuglog<<std::string(time_str()+": info: found password in database for key ID: "+inkeyid+", trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" with password"); + debuglog<<std::string(time_str()+": info: found password in database for key ID: "+inkeyid+", trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" with password"); } else { pass = UniGetContactSettingUtf(NULL, szGPGModuleName, "szKeyPassword", _T("")); if(pass[0] && bDebugLog) - debuglog<<std::string(time_str()+": info: found password for all keys in database, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" with password"); + debuglog<<std::string(time_str()+": info: found password for all keys in database, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" with password"); } if(pass && pass[0]) { @@ -120,12 +120,12 @@ void RecvMsgSvc_func(MCONTACT hContact, std::wstring str, char *msg, DWORD flags else if(password && password[0]) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: found password in memory, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" with password"); + debuglog<<std::string(time_str()+": info: found password in memory, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" with password"); cmd.push_back(L"--passphrase"); cmd.push_back(password); } else if (bDebugLog) - debuglog<<std::string(time_str()+": info: passwords not found in database or memory, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" with out password"); + debuglog<<std::string(time_str()+": info: passwords not found in database or memory, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" with out password"); mir_free(pass); mir_free(inkeyid); } @@ -175,7 +175,7 @@ void RecvMsgSvc_func(MCONTACT hContact, std::wstring str, char *msg, DWORD flags while(out.find("public key decryption failed: bad passphrase") != string::npos) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: failed to decrypt messaage from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" password needed, trying to get one"); + debuglog<<std::string(time_str()+": info: failed to decrypt messaage from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" password needed, trying to get one"); if(_terminate) { BYTE enc = db_get_b(hContact, szGPGModuleName, "GPGEncryption", 0); @@ -200,7 +200,7 @@ void RecvMsgSvc_func(MCONTACT hContact, std::wstring str, char *msg, DWORD flags if(password) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: found password in memory, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info: found password in memory, trying to decrypt message from "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); std::vector<wstring> tmp; tmp.push_back(L"--passphrase"); tmp.push_back(password); @@ -608,7 +608,7 @@ void SendMsgSvc_func(MCONTACT hContact, char *msg, DWORD flags) if(bStripTags && bAppendTags) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: stripping tags in outgoing message, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info: stripping tags in outgoing message, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); strip_tags(str); } /* for(std::wstring::size_type i = str.find(_T("\r\n")); i != std::wstring::npos; i = str.find(_T("\r\n"), i+1)) @@ -772,14 +772,14 @@ void SendMsgSvc_func(MCONTACT hContact, char *msg, DWORD flags) hcontact_data[metaGetContact(hContact)].msgs_to_pass.push_back(str_event); if(bDebugLog) { - debuglog<<std::string(time_str() + toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR)) +"is subcontact of" + toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)metaGetContact(hContact), GCDNF_TCHAR))); + debuglog<<std::string(time_str() + toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR)) +"is subcontact of" + toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)metaGetContact(hContact), GCDNF_TCHAR))); debuglog<<std::string(time_str()+": adding event to metacontact: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)metaGetContact(hContact), GCDNF_TCHAR))+" on send message."); } HistoryLog(metaGetContact(hContact), db_event((char*)str_event.c_str(), 0,0, DBEF_SENT|dbflags)); }*/ //unneeded ? // hcontact_data[hContact].msgs_to_pass.push_back(str_event); if(bDebugLog) - debuglog<<std::string(time_str()+": adding event to contact: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" on send message."); + debuglog<<std::string(time_str()+": adding event to contact: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" on send message."); //HistoryLog(hContact, db_event((char*)str_event.c_str(), 0,0, dbflags|DBEF_SENT)); if(!(flags & PREF_UTF)) flags |= PREF_UTF; @@ -844,13 +844,13 @@ int HookSendMsg(WPARAM w, LPARAM l) if(isContactSecured(hContact) && strstr((char*)dbei->pBlob, "-----BEGIN PGP MESSAGE-----")) //our service data, can be double added by metacontacts e.t.c. { if(bDebugLog) - debuglog<<std::string(time_str()+": info(send handler): block pgp message event, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(send handler): block pgp message event, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); return 1; } if(bAutoExchange && (strstr((char*)dbei->pBlob, "-----PGP KEY RESPONSE-----") || strstr((char*)dbei->pBlob, "-----PGP KEY REQUEST-----"))) ///do not show service data in history { if(bDebugLog) - debuglog<<std::string(time_str()+": info(send handler): block pgp key request/response event, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(send handler): block pgp key request/response event, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); return 1; } } @@ -860,27 +860,27 @@ int HookSendMsg(WPARAM w, LPARAM l) if(!isContactHaveKey(hContact)) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: contact have not key, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info: contact have not key, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); if(bAutoExchange && !strstr((char*)dbei->pBlob, "-----PGP KEY REQUEST-----") && !strstr((char*)dbei->pBlob, "-----BEGIN PGP PUBLIC KEY BLOCK-----") && gpg_valid) { if(bDebugLog) - debuglog<<std::string(time_str()+": info: checking for autoexchange possibility, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info: checking for autoexchange possibility, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); LPSTR proto = GetContactProto(hContact); DWORD uin = db_get_dw(hContact, proto, "UIN", 0); if(uin) { if(bDebugLog) - debuglog<<std::string(time_str()+": info(autoexchange): protocol looks like icq, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(autoexchange): protocol looks like icq, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); char *proto = GetContactProto(hContact); if( ProtoServiceExists(proto, PS_ICQ_CHECKCAPABILITY)) { if(bDebugLog) - debuglog<<std::string(time_str()+": info(autoexchange, icq): checking for autoexchange icq capability, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(autoexchange, icq): checking for autoexchange icq capability, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); ICQ_CUSTOMCAP cap = {0}; strcpy(cap.caps, "GPG AutoExchange"); - if( ProtoCallService(proto, PS_ICQ_CHECKCAPABILITY, (WPARAM)hContact, (LPARAM)&cap)) { + if( ProtoCallService(proto, PS_ICQ_CHECKCAPABILITY, hContact, (LPARAM)&cap)) { if(bDebugLog) - debuglog<<std::string(time_str()+": info(autoexchange, icq): sending key requiest, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(autoexchange, icq): sending key requiest, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); CallContactService(hContact, PSS_MESSAGE, (dbei->flags & DBEF_UTF) ? PREF_UTF : 0, (LPARAM)"-----PGP KEY REQUEST-----"); hcontact_data[hContact].msgs_to_send.push_back((char*)dbei->pBlob); boost::thread *thr = new boost::thread(boost::bind(send_encrypted_msgs_thread, (void*)hContact)); @@ -895,7 +895,7 @@ int HookSendMsg(WPARAM w, LPARAM l) if(jid[0]) { if(bDebugLog) - debuglog<<std::string(time_str()+": info(autoexchange): protocol looks like jabber, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(autoexchange): protocol looks like jabber, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); extern list <JabberAccount*> Accounts; list<JabberAccount*>::iterator end = Accounts.end(); for(list<JabberAccount*>::iterator p = Accounts.begin(); p != end; p++) @@ -915,7 +915,7 @@ int HookSendMsg(WPARAM w, LPARAM l) if(str.find(_T("GPG_Key_Auto_Exchange:0")) != string::npos) { if(bDebugLog) - debuglog<<std::string(time_str()+": info(autoexchange, jabber): autoexchange capability found, sending key request, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(autoexchange, jabber): autoexchange capability found, sending key request, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); CallContactService(hContact, PSS_MESSAGE, (dbei->flags & DBEF_UTF) ? PREF_UTF : 0, (LPARAM)"-----PGP KEY REQUEST-----"); hcontact_data[hContact].msgs_to_send.push_back((char*)dbei->pBlob); boost::thread *thr = new boost::thread(boost::bind(send_encrypted_msgs_thread, (void*)hContact)); @@ -968,7 +968,7 @@ int HookSendMsg(WPARAM w, LPARAM l) { hcontact_data[hContact].msgs_to_pass.erase(i); if(bDebugLog) - debuglog<<std::string(time_str()+": event message: \""+(char*)dbei->pBlob+"\" passed event filter, contact "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+", message is in allowed list"); + debuglog<<std::string(time_str()+": event message: \""+(char*)dbei->pBlob+"\" passed event filter, contact "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+", message is in allowed list"); event_processing_mutex.unlock(); return 0; } @@ -983,7 +983,7 @@ int HookSendMsg(WPARAM w, LPARAM l) if(!isContactSecured(hContact)) { if(bDebugLog) - debuglog<<std::string(time_str()+": event message: \""+(char*)dbei->pBlob+"\" passed event filter, contact "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))+" is unsecured"); + debuglog<<std::string(time_str()+": event message: \""+(char*)dbei->pBlob+"\" passed event filter, contact "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))+" is unsecured"); return 0; } if(!(dbei->flags & DBEF_SENT) && metaIsProtoMetaContacts((MCONTACT)w)) @@ -994,7 +994,7 @@ int HookSendMsg(WPARAM w, LPARAM l) if(strstr(tmp, "-----BEGIN PGP MESSAGE-----")) { if(bDebugLog) - debuglog<<std::string(time_str()+": info(send handler): block pgp message event, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": info(send handler): block pgp message event, name: "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); return 1; } } diff --git a/plugins/New_GPG/src/metacontacts.cpp b/plugins/New_GPG/src/metacontacts.cpp index 31b320737c..876071191a 100644 --- a/plugins/New_GPG/src/metacontacts.cpp +++ b/plugins/New_GPG/src/metacontacts.cpp @@ -32,7 +32,7 @@ bool metaIsProtoMetaContacts(MCONTACT hContact) bool metaIsDefaultSubContact(MCONTACT hContact)
{
if(bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT,(WPARAM)CallService(MS_MC_GETMETACONTACT,(WPARAM)hContact,0),0)==hContact;
+ return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT,(WPARAM)CallService(MS_MC_GETMETACONTACT,hContact,0),0)==hContact;
return false;
}
@@ -40,14 +40,14 @@ MCONTACT metaGetContact(MCONTACT hContact) {
if(bMetaContacts)
if(metaIsSubcontact(hContact))
- return (MCONTACT)CallService(MS_MC_GETMETACONTACT,(WPARAM)hContact,0);
+ return (MCONTACT)CallService(MS_MC_GETMETACONTACT,hContact,0);
return NULL;
}
bool metaIsSubcontact(MCONTACT hContact)
{
if(bMetaContacts)
- return CallService(MS_MC_GETMETACONTACT,(WPARAM)hContact,0) != 0;
+ return CallService(MS_MC_GETMETACONTACT,hContact,0) != 0;
return false;
}
@@ -55,7 +55,7 @@ MCONTACT metaGetMostOnline(MCONTACT hContact) {
if(bMetaContacts)
if(metaIsProtoMetaContacts(hContact))
- return (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT,(WPARAM)hContact,0);
+ return (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT,hContact,0);
return NULL;
}
@@ -63,20 +63,20 @@ MCONTACT metaGetDefault(MCONTACT hContact) {
if(bMetaContacts)
if(metaIsProtoMetaContacts(hContact))
- return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT,(WPARAM)hContact,0);
+ return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT,hContact,0);
return NULL;
}
DWORD metaGetContactsNum(MCONTACT hContact)
{
if(bMetaContacts)
- return CallService(MS_MC_GETNUMCONTACTS, (WPARAM)hContact, 0);
+ return CallService(MS_MC_GETNUMCONTACTS, hContact, 0);
return 0;
}
MCONTACT metaGetSubcontact(MCONTACT hContact, int num)
{
if(bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETSUBCONTACT, (WPARAM)hContact, (LPARAM)num);
+ return (MCONTACT)CallService(MS_MC_GETSUBCONTACT, hContact, (LPARAM)num);
return 0;
}
diff --git a/plugins/New_GPG/src/options.cpp b/plugins/New_GPG/src/options.cpp index 019036e6ce..cf05777171 100755 --- a/plugins/New_GPG/src/options.cpp +++ b/plugins/New_GPG/src/options.cpp @@ -122,7 +122,7 @@ static INT_PTR CALLBACK DlgProcGpgOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP int i = 1, iRow = 0;
for(MCONTACT hContact = db_find_first(); hContact != NULL; hContact = db_find_next(hContact)) {
if(isContactHaveKey(hContact)) {
- TCHAR *name = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *name = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
item.mask = LVIF_TEXT;
item.iItem = i;
item.iSubItem = 0;
diff --git a/plugins/New_GPG/src/utilities.cpp b/plugins/New_GPG/src/utilities.cpp index c2d1be1b0f..c20a6645de 100755 --- a/plugins/New_GPG/src/utilities.cpp +++ b/plugins/New_GPG/src/utilities.cpp @@ -1076,7 +1076,7 @@ bool isContactSecured(MCONTACT hContact) if(!gpg_enc) { if(bDebugLog) - debuglog<<std::string(time_str()+": encryption is turned off for "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": encryption is turned off for "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); return false; } if(!metaIsProtoMetaContacts(hContact)) @@ -1086,13 +1086,13 @@ bool isContactSecured(MCONTACT hContact) { mir_free(key); if(bDebugLog) - debuglog<<std::string(time_str()+": encryption is turned off for "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": encryption is turned off for "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); return false; } mir_free(key); } if(bDebugLog) - debuglog<<std::string(time_str()+": encryption is turned on for "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR))); + debuglog<<std::string(time_str()+": encryption is turned on for "+toUTF8((TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR))); return true; } diff --git a/plugins/NewsAggregator/Src/ExportImport.cpp b/plugins/NewsAggregator/Src/ExportImport.cpp index 3dc225ec06..124d1981c0 100644 --- a/plugins/NewsAggregator/Src/ExportImport.cpp +++ b/plugins/NewsAggregator/Src/ExportImport.cpp @@ -149,7 +149,7 @@ INT_PTR CALLBACK DlgProcImportOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM }
MCONTACT hContact = (MCONTACT)CallService(MS_DB_CONTACT_ADD, 0, 0);
- CallService(MS_PROTO_ADDTOCONTACT, (WPARAM)hContact, (LPARAM)MODULE);
+ CallService(MS_PROTO_ADDTOCONTACT, hContact, (LPARAM)MODULE);
db_set_ts(hContact, MODULE, "Nick", title);
db_set_ts(hContact, MODULE, "URL", url);
db_set_ts(hContact, MODULE, "Homepage", siteurl);
diff --git a/plugins/NewsAggregator/Src/Options.cpp b/plugins/NewsAggregator/Src/Options.cpp index c2c64edd6b..0b9ad7ec4d 100644 --- a/plugins/NewsAggregator/Src/Options.cpp +++ b/plugins/NewsAggregator/Src/Options.cpp @@ -58,7 +58,7 @@ INT_PTR CALLBACK DlgProcAddFeedOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA }
MCONTACT hContact = (MCONTACT)CallService(MS_DB_CONTACT_ADD, 0, 0);
- CallService(MS_PROTO_ADDTOCONTACT, (WPARAM)hContact, (LPARAM)MODULE);
+ CallService(MS_PROTO_ADDTOCONTACT, hContact, (LPARAM)MODULE);
GetDlgItemText(hwndDlg, IDC_FEEDTITLE, str, SIZEOF(str));
db_set_ts(hContact, MODULE, "Nick", str);
HWND hwndList = (HWND)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
@@ -518,7 +518,7 @@ INT_PTR CALLBACK UpdateNotifyOptsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPA if ( lstrcmp(dbURL, url))
continue;
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0);
+ CallService(MS_DB_CONTACT_DELETE, hContact, 0);
ListView_DeleteItem(hwndList, sel);
break;
}
diff --git a/plugins/NoHistory/src/dllmain.cpp b/plugins/NoHistory/src/dllmain.cpp index 6b13f688ea..82fc7ce945 100644 --- a/plugins/NoHistory/src/dllmain.cpp +++ b/plugins/NoHistory/src/dllmain.cpp @@ -221,7 +221,7 @@ int IconPressed(WPARAM hContact, LPARAM lParam) char *proto = GetContactProto(hContact);
bool chat_room = (proto && db_get_b(hContact, proto, "ChatRoom", 0) != 0);
if (!chat_room)
- ServiceToggle((WPARAM)hContact, 0);
+ ServiceToggle(hContact, 0);
return 0;
}
diff --git a/plugins/NoHistory/src/options.cpp b/plugins/NoHistory/src/options.cpp index a963e796a0..684d7bdc5a 100644 --- a/plugins/NoHistory/src/options.cpp +++ b/plugins/NoHistory/src/options.cpp @@ -89,7 +89,7 @@ static void SetAllContactIcons(HWND hwndList) bool chat_room = (proto && db_get_b(hContact, proto, "ChatRoom", 0) != 0);
if (!chat_room) {
- HANDLE hItem=(HANDLE)SendMessage(hwndList,CLM_FINDCONTACT,(WPARAM)hContact,0);
+ HANDLE hItem=(HANDLE)SendMessage(hwndList,CLM_FINDCONTACT,hContact,0);
if (hItem) {
bool disabled = (db_get_b(hContact, MODULE, DBSETTING_REMOVE, 0) == 1);
SendMessage(hwndList,CLM_SETEXTRAIMAGE,(WPARAM)hItem,MAKELPARAM(0,disabled?1:0));
@@ -203,7 +203,7 @@ static INT_PTR CALLBACK DlgProcOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA bool chat_room = (proto && db_get_b(hContact, proto, "ChatRoom", 0) != 0);
if (!chat_room) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList,CLM_FINDCONTACT,(WPARAM)hContact,0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList,CLM_FINDCONTACT,hContact,0);
if (hItem) {
int iImage = SendMessage(hwndList,CLM_GETEXTRAIMAGE,(WPARAM)hItem,MAKELPARAM(0,0));
db_set_b(hContact, MODULE, DBSETTING_REMOVE, iImage==1?1:0);
diff --git a/plugins/Non-IM Contact/src/contactinfo.cpp b/plugins/Non-IM Contact/src/contactinfo.cpp index 2daea133e2..bb7da6cdd7 100644 --- a/plugins/Non-IM Contact/src/contactinfo.cpp +++ b/plugins/Non-IM Contact/src/contactinfo.cpp @@ -635,8 +635,8 @@ INT_PTR ImportContacts(WPARAM wParam, LPARAM lParam) msg("contact did get created","");
continue;
}
- CallService(MS_PROTO_ADDTOCONTACT,(WPARAM)hContact,(LPARAM)MODNAME);
- CallService(MS_IGNORE_IGNORE, (WPARAM)hContact, IGNOREEVENT_USERONLINE);
+ CallService(MS_PROTO_ADDTOCONTACT,hContact,(LPARAM)MODNAME);
+ CallService(MS_IGNORE_IGNORE, hContact, IGNOREEVENT_USERONLINE);
db_set_s(hContact, MODNAME, "Nick", Translate("New Non-IM Contact"));
db_set_s(hContact, MODNAME, "Name", name);
db_set_s(hContact, MODNAME, "ProgramString", program);
diff --git a/plugins/Non-IM Contact/src/dialog.cpp b/plugins/Non-IM Contact/src/dialog.cpp index 2cf8ce46f7..0b79653a20 100644 --- a/plugins/Non-IM Contact/src/dialog.cpp +++ b/plugins/Non-IM Contact/src/dialog.cpp @@ -308,12 +308,12 @@ INT_PTR addContact(WPARAM wParam,LPARAM lParam) {
char tmp[256];
MCONTACT hContact = (MCONTACT) CallService(MS_DB_CONTACT_ADD, 0, 0);
- CallService(MS_PROTO_ADDTOCONTACT,(WPARAM)hContact,(LPARAM)MODNAME);
- CallService(MS_IGNORE_IGNORE, (WPARAM)hContact, IGNOREEVENT_USERONLINE);
+ CallService(MS_PROTO_ADDTOCONTACT,hContact,(LPARAM)MODNAME);
+ CallService(MS_IGNORE_IGNORE, hContact, IGNOREEVENT_USERONLINE);
db_set_ts(hContact, MODNAME, "Nick", TranslateT("New Non-IM Contact"));
DoPropertySheet(hContact, hInst);
if (!db_get_static(hContact, MODNAME, "Name", tmp))
- CallService(MS_DB_CONTACT_DELETE,(WPARAM)hContact,0);
+ CallService(MS_DB_CONTACT_DELETE,hContact,0);
replaceAllStrings(hContact);
return 0;
}
@@ -324,13 +324,13 @@ INT_PTR editContact(WPARAM wParam,LPARAM lParam) char tmp[256];
if (!hContact) {
hContact = (MCONTACT)CallService(MS_DB_CONTACT_ADD, 0, 0);
- CallService(MS_PROTO_ADDTOCONTACT,(WPARAM)hContact,(LPARAM)MODNAME);
- CallService(MS_IGNORE_IGNORE, (WPARAM)hContact, IGNOREEVENT_USERONLINE);
+ CallService(MS_PROTO_ADDTOCONTACT,hContact,(LPARAM)MODNAME);
+ CallService(MS_IGNORE_IGNORE, hContact, IGNOREEVENT_USERONLINE);
db_set_s(hContact, MODNAME, "Nick", Translate("New Non-IM Contact"));
}
DoPropertySheet(hContact, hInst);
if (!db_get_static(hContact, MODNAME, "Name", tmp))
- CallService(MS_DB_CONTACT_DELETE,(WPARAM)hContact,0);
+ CallService(MS_DB_CONTACT_DELETE,hContact,0);
replaceAllStrings(hContact);
return 0;
}
diff --git a/plugins/Nudge/src/main.cpp b/plugins/Nudge/src/main.cpp index c79da2dd8c..1c19a70d78 100644 --- a/plugins/Nudge/src/main.cpp +++ b/plugins/Nudge/src/main.cpp @@ -259,7 +259,7 @@ void HideNudgeButton(MCONTACT hContact) bbd.bbbFlags = BBSF_HIDDEN | BBSF_DISABLED;
bbd.pszModuleName = "Nudge";
bbd.dwButtonID = 6000;
- CallService(MS_BB_SETBUTTONSTATE, (WPARAM)hContact, (LPARAM)&bbd);
+ CallService(MS_BB_SETBUTTONSTATE, hContact, (LPARAM)&bbd);
}
}
@@ -389,9 +389,9 @@ int Preview() if (n->item.shakeClist)
ShakeClist(0, 0);
if (n->item.openMessageWindow)
- CallService(MS_MSG_SENDMESSAGET, (WPARAM)hContact, NULL);
+ CallService(MS_MSG_SENDMESSAGET, hContact, NULL);
if (n->item.shakeChat)
- ShakeChat((WPARAM)hContact, (LPARAM)time(NULL));
+ ShakeChat(hContact, (LPARAM)time(NULL));
}
}
}
@@ -405,9 +405,9 @@ int Preview() if (DefaultNudge.shakeClist)
ShakeClist(0, 0);
if (DefaultNudge.openMessageWindow)
- CallService(MS_MSG_SENDMESSAGET, (WPARAM)hContact, NULL);
+ CallService(MS_MSG_SENDMESSAGET, hContact, NULL);
if (DefaultNudge.shakeChat)
- ShakeChat((WPARAM)hContact, (LPARAM)time(NULL));
+ ShakeChat(hContact, (LPARAM)time(NULL));
}
}
return 0;
@@ -416,7 +416,7 @@ int Preview() void Nudge_ShowPopup(CNudgeElement n, MCONTACT hContact, TCHAR * Message)
{
hContact = Nudge_GethContact(hContact);
- TCHAR * lpzContactName = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR * lpzContactName = (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
if (ServiceExists(MS_POPUP_ADDPOPUPCLASS)) {
POPUPDATACLASS NudgePopup = { 0 };
@@ -459,7 +459,7 @@ void Nudge_SentStatus(CNudgeElement n, MCONTACT hContact) dbei.cbBlob = (DWORD)strlen(buff) + 1;
dbei.pBlob = (PBYTE)buff;
- INT_PTR res = CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0); //try to retrieve the metacontact if some
+ INT_PTR res = CallService(MS_MC_GETMETACONTACT, hContact, 0); //try to retrieve the metacontact if some
if (res != CALLSERVICE_NOTFOUND) {
MCONTACT hMetaContact = (MCONTACT)res;
if (hMetaContact != NULL) // metacontact
@@ -482,7 +482,7 @@ void Nudge_ShowStatus(CNudgeElement n, MCONTACT hContact, DWORD timestamp) dbei.cbBlob = (DWORD)strlen(buff) + 1;
dbei.pBlob = (PBYTE)buff;
- INT_PTR res = CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0); //try to retrieve the metacontact if some
+ INT_PTR res = CallService(MS_MC_GETMETACONTACT, hContact, 0); //try to retrieve the metacontact if some
if (res != CALLSERVICE_NOTFOUND) {
MCONTACT hMetaContact = (MCONTACT)res;
if (hMetaContact != NULL) { //metacontact
@@ -497,7 +497,7 @@ void Nudge_ShowStatus(CNudgeElement n, MCONTACT hContact, DWORD timestamp) MCONTACT Nudge_GethContact(MCONTACT hContact)
{
- INT_PTR res = CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ INT_PTR res = CallService(MS_MC_GETMETACONTACT, hContact, 0);
if (res != CALLSERVICE_NOTFOUND) {
MCONTACT hMetaContact = (MCONTACT)res;
if (hMetaContact != NULL)
diff --git a/plugins/PasteIt/src/PasteIt.cpp b/plugins/PasteIt/src/PasteIt.cpp index 05f28e0421..633ceb92f6 100644 --- a/plugins/PasteIt/src/PasteIt.cpp +++ b/plugins/PasteIt/src/PasteIt.cpp @@ -172,7 +172,7 @@ void PasteIt(MCONTACT hContact, int mode) }
// Send message to focus window
- CallServiceSync(MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
+ CallServiceSync(MS_MSG_SENDMESSAGE, hContact, 0);
}
else
{
@@ -192,17 +192,17 @@ void PasteIt(MCONTACT hContact, int mode) // to focus window.
SendMessage(it->second, EM_SETSEL, -1, SendMessage(it->second, WM_GETTEXTLENGTH, 0, 0));
SendMessageA(it->second, EM_REPLACESEL, FALSE, (LPARAM)pasteToWeb->szFileLink);
- CallServiceSync(MS_MSG_SENDMESSAGE, (WPARAM)hContact, NULL);
+ CallServiceSync(MS_MSG_SENDMESSAGE, hContact, NULL);
}
else
{
// If window do not exist, maybe it is not chat
- CallServiceSync(MS_MSG_SENDMESSAGE, (WPARAM)hContact, (LPARAM)pasteToWeb->szFileLink);
+ CallServiceSync(MS_MSG_SENDMESSAGE, hContact, (LPARAM)pasteToWeb->szFileLink);
}
}
else
{
- CallServiceSync(MS_MSG_SENDMESSAGE, (WPARAM)hContact, (LPARAM)pasteToWeb->szFileLink);
+ CallServiceSync(MS_MSG_SENDMESSAGE, hContact, (LPARAM)pasteToWeb->szFileLink);
}
}
}
diff --git a/plugins/Popup/src/avatars.cpp b/plugins/Popup/src/avatars.cpp index 2130268d52..67637b4e6b 100644 --- a/plugins/Popup/src/avatars.cpp +++ b/plugins/Popup/src/avatars.cpp @@ -29,7 +29,7 @@ PopupAvatar *PopupAvatar::create(MCONTACT hContact) {
if (ServiceExists(MS_AV_GETAVATARBITMAP))
{
- avatarCacheEntry *av = (avatarCacheEntry *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ avatarCacheEntry *av = (avatarCacheEntry *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
// MessageBox(NULL, _T("00"), _T(MODULNAME_LONG), MB_OK);
if (av && (_tcslen(av->szFilename) > 4))
{
diff --git a/plugins/Popup/src/avatars_gif.cpp b/plugins/Popup/src/avatars_gif.cpp index c672f235b5..6e55e7d60e 100644 --- a/plugins/Popup/src/avatars_gif.cpp +++ b/plugins/Popup/src/avatars_gif.cpp @@ -25,7 +25,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. GifAvatar::GifAvatar(MCONTACT hContact): PopupAvatar((HANDLE)hContact)
{
- av = (avatarCacheEntry *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ av = (avatarCacheEntry *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
bIsAnimated = true;
bIsValid = true;
GDIPlus_GetGIFSize(av->szFilename, &this->width, &this->height);
diff --git a/plugins/Popup/src/opt_contacts.cpp b/plugins/Popup/src/opt_contacts.cpp index 1e0fd7a01d..920c378d3a 100644 --- a/plugins/Popup/src/opt_contacts.cpp +++ b/plugins/Popup/src/opt_contacts.cpp @@ -86,7 +86,7 @@ INT_PTR CALLBACK DlgProcContactOpts(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l case PSN_APPLY:
HWND hwndList = GetDlgItem(hwnd, IDC_LIST);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
for (int i=0; i < 4 /*SIZEOF(sttIcons)*/; ++i) {
if (SendMessage(hwndList,CLM_GETEXTRAIMAGE,(WPARAM)hItem,MAKELPARAM(i,0))) {
db_set_b(hContact, MODULNAME, "ShowMode", i);
@@ -118,7 +118,7 @@ static void sttResetListOptions(HWND hwndList) static void sttSetAllContactIcons(HWND hwndList)
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
DWORD dwMode = db_get_b(hContact, MODULNAME, "ShowMode", 0);
for (int i=0; i < 4 /*SIZEOF(sttIcons)*/; ++i)
//hIml element [0] = SKINICON_OTHER_SMALLDOT
diff --git a/plugins/Popup/src/popup_wnd2.cpp b/plugins/Popup/src/popup_wnd2.cpp index 608d0394dd..f73e3f86a1 100644 --- a/plugins/Popup/src/popup_wnd2.cpp +++ b/plugins/Popup/src/popup_wnd2.cpp @@ -943,7 +943,7 @@ BOOL IsUtfSendAvailable(MCONTACT hContact) if (szProto == NULL) return FALSE;
//check for MetaContact and get szProto from subcontact
if (strcmp(szProto, gszMetaProto)==0) {
- MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT, (WPARAM)hContact, 0);
+ MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT, hContact, 0);
if (!hSubContact)
return FALSE;
szProto = GetContactProto(hSubContact);
@@ -1500,7 +1500,7 @@ LRESULT CALLBACK MenuHostWndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM {
hContact = lParam;
POINT pt = {0};
- HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT,(WPARAM)hContact,0);
+ HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT,hContact,0);
GetCursorPos(&pt);
HWND hwndSave = GetForegroundWindow();
SetForegroundWindow(hwnd);
diff --git a/plugins/QuickContacts/src/quickcontacts.cpp b/plugins/QuickContacts/src/quickcontacts.cpp index 32e17cb3a7..82c92f15cb 100644 --- a/plugins/QuickContacts/src/quickcontacts.cpp +++ b/plugins/QuickContacts/src/quickcontacts.cpp @@ -366,7 +366,7 @@ void LoadContacts(HWND hwndDlg, BOOL show_all) if (metacontactsEnabled)
{
if ((!show_all && opts.hide_subcontacts) || opts.group_append)
- hMeta = (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ hMeta = (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0);
}
else
{
@@ -489,7 +489,7 @@ void EnableButtons(HWND hwndDlg, MCONTACT hContact) caps = CallProtoService(pszProto, PS_GETCAPS, PFLAGNUM_1, 0);
BOOL voice = (ServiceExists(MS_VOICESERVICE_CAN_CALL)
- && CallService(MS_VOICESERVICE_CAN_CALL, (WPARAM)hContact, 0) > 0);
+ && CallService(MS_VOICESERVICE_CAN_CALL, hContact, 0) > 0);
EnableWindow(GetDlgItem(hwndDlg, IDC_MESSAGE), caps & PF1_IMSEND ? TRUE : FALSE);
EnableWindow(GetDlgItem(hwndDlg, IDC_VOICE), voice);
diff --git a/plugins/QuickMessages/src/Utils.cpp b/plugins/QuickMessages/src/Utils.cpp index 2612d16950..a32da0453b 100644 --- a/plugins/QuickMessages/src/Utils.cpp +++ b/plugins/QuickMessages/src/Utils.cpp @@ -499,7 +499,7 @@ TCHAR* ParseString(MCONTACT hContact,TCHAR* ptszQValIn,TCHAR* ptszText,TCHAR* pt int NameLenght=0;
TCHAR* ptszName=NULL;
- ptszName=(TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ ptszName=(TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
NameLenght=(int)_tcslen(ptszName);
p = (TCHAR *)realloc(tempQValue, (QVSize + NameLenght + 1)*sizeof(TCHAR));
if(p){
diff --git a/plugins/RemovePersonalSettings/src/rps.cpp b/plugins/RemovePersonalSettings/src/rps.cpp index 449747b22d..a4d693c3ac 100644 --- a/plugins/RemovePersonalSettings/src/rps.cpp +++ b/plugins/RemovePersonalSettings/src/rps.cpp @@ -238,7 +238,7 @@ void RemoveUsers() // Now delete all left-overs
hContact = db_find_first();
while(hContact != NULL) {
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0);
+ CallService(MS_DB_CONTACT_DELETE, hContact, 0);
hContact = db_find_first();
}
diff --git a/plugins/SMS/src/SMS_svc.cpp b/plugins/SMS/src/SMS_svc.cpp index 09578a6dd7..67de9d801c 100644 --- a/plugins/SMS/src/SMS_svc.cpp +++ b/plugins/SMS/src/SMS_svc.cpp @@ -140,7 +140,7 @@ void RestoreUnreadMessageAlerts(void) if (db_event_get(hDbEvent, &dbei) == 0)
if ((dbei.flags & (DBEF_SENT|DBEF_READ))==0 && ((dbei.eventType==ICQEVENTTYPE_SMS) || (dbei.eventType==ICQEVENTTYPE_SMSCONFIRMATION)))
if (dbei.cbBlob>MIN_SMS_DBEVENT_LEN)
- handleNewMessage((WPARAM)hContact,(LPARAM)hDbEvent);
+ handleNewMessage(hContact,(LPARAM)hDbEvent);
}
for (HANDLE hDbEvent = db_event_firstUnread(NULL); hDbEvent; hDbEvent = db_event_next(hDbEvent)) {
diff --git a/plugins/Scriver/src/msglog.cpp b/plugins/Scriver/src/msglog.cpp index cb59b9b61b..247f60ceb8 100644 --- a/plugins/Scriver/src/msglog.cpp +++ b/plugins/Scriver/src/msglog.cpp @@ -168,7 +168,7 @@ EventData* getEventFromDB(struct SrmmWindowData *dat, MCONTACT hContact, HANDLE evt->custom = DbEventIsCustomForMsgWindow(&dbei);
if (!(dbei.flags & DBEF_SENT) && (dbei.eventType == EVENTTYPE_MESSAGE || dbei.eventType == EVENTTYPE_URL || evt->custom)) {
db_event_markRead(hContact, hDbEvent);
- CallService(MS_CLIST_REMOVEEVENT, (WPARAM)hContact, (LPARAM)hDbEvent);
+ CallService(MS_CLIST_REMOVEEVENT, hContact, (LPARAM)hDbEvent);
}
else if (dbei.eventType == EVENTTYPE_JABBER_CHATSTATES || dbei.eventType == EVENTTYPE_JABBER_PRESENCE)
db_event_markRead(hContact, hDbEvent);
diff --git a/plugins/Scriver/src/msgoptions.cpp b/plugins/Scriver/src/msgoptions.cpp index d7413db3f1..097542c3a7 100644 --- a/plugins/Scriver/src/msgoptions.cpp +++ b/plugins/Scriver/src/msgoptions.cpp @@ -846,7 +846,7 @@ static void RebuildList(HWND hwndDlg, HANDLE hItemNew, HANDLE hItemUnknown) SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItemUnknown, 1);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem && db_get_b(hContact, SRMMMOD, SRMSGSET_TYPING, defType))
SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, 1);
}
@@ -861,7 +861,7 @@ static void SaveList(HWND hwndDlg, HANDLE hItemNew, HANDLE hItemUnknown) db_set_b(NULL, SRMMMOD, SRMSGSET_TYPINGUNKNOWN, (BYTE)(SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItemUnknown, 0) ? 1 : 0));
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem)
db_set_b(hContact, SRMMMOD, SRMSGSET_TYPING, (BYTE)(SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItem, 0) ? 1 : 0));
}
diff --git a/plugins/Scriver/src/msgs.cpp b/plugins/Scriver/src/msgs.cpp index 175e2fae32..2b9a150689 100644 --- a/plugins/Scriver/src/msgs.cpp +++ b/plugins/Scriver/src/msgs.cpp @@ -63,7 +63,7 @@ int IsAutoPopup(MCONTACT hContact) { if (g_dat.flags & SMF_AUTOPOPUP) {
char *szProto = GetContactProto(hContact);
if (strcmp(szProto, "MetaContacts") == 0 ) {
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (hContact != NULL)
szProto = GetContactProto(hContact);
}
diff --git a/plugins/Scriver/src/msgwindow.cpp b/plugins/Scriver/src/msgwindow.cpp index f51ea244eb..5a13a81d9d 100644 --- a/plugins/Scriver/src/msgwindow.cpp +++ b/plugins/Scriver/src/msgwindow.cpp @@ -67,7 +67,7 @@ TCHAR* GetWindowTitle(MCONTACT hContact, const char *szProto) tokenLen[2] = j;
}
- accModule = (char*)CallService(MS_PROTO_GETCONTACTBASEACCOUNT, (WPARAM)hContact, 0);
+ accModule = (char*)CallService(MS_PROTO_GETCONTACTBASEACCOUNT, hContact, 0);
if (accModule != NULL) {
PROTOACCOUNT* proto = (PROTOACCOUNT*)CallService(MS_PROTO_GETACCOUNT, 0, (LPARAM)accModule);
if (proto != NULL) {
diff --git a/plugins/Scriver/src/statusicon.cpp b/plugins/Scriver/src/statusicon.cpp index 43fade35d8..2c7ba945a6 100644 --- a/plugins/Scriver/src/statusicon.cpp +++ b/plugins/Scriver/src/statusicon.cpp @@ -56,7 +56,7 @@ void CheckStatusIconClick(MCONTACT hContact, HWND hwndFrom, POINT pt, RECT r, in sicd.dwId = si->dwId;
sicd.szModule = si->szModule;
sicd.flags = click_flags;
- NotifyEventHooks(hHookIconPressedEvt, (WPARAM)hContact, (LPARAM)&sicd);
+ NotifyEventHooks(hHookIconPressedEvt, hContact, (LPARAM)&sicd);
}
static int OnSrmmIconChanged(WPARAM hContact, LPARAM)
diff --git a/plugins/SecureIM/src/crypt_icons.cpp b/plugins/SecureIM/src/crypt_icons.cpp index f4eb6b75c2..1aa8a4f578 100644 --- a/plugins/SecureIM/src/crypt_icons.cpp +++ b/plugins/SecureIM/src/crypt_icons.cpp @@ -100,7 +100,7 @@ void ShowStatusIcon(MCONTACT hContact) void ShowStatusIconNotify(MCONTACT hContact)
{
BYTE mode = isContactSecured(hContact);
- NotifyEventHooks(g_hEvent[(mode&SECURED) != 0], (WPARAM)hContact, 0);
+ NotifyEventHooks(g_hEvent[(mode&SECURED) != 0], hContact, 0);
ShowStatusIcon(hContact,mode);
}
diff --git a/plugins/SecureIM/src/crypt_lists.cpp b/plugins/SecureIM/src/crypt_lists.cpp index c8727ed04a..ab44379d45 100644 --- a/plugins/SecureIM/src/crypt_lists.cpp +++ b/plugins/SecureIM/src/crypt_lists.cpp @@ -65,7 +65,7 @@ void freeSupportedProtocols() pSupPro getSupPro(MCONTACT hContact)
{
for (int j=0; j < arProto.getCount(); j++)
- if (CallService(MS_PROTO_ISPROTOONCONTACT, (WPARAM)hContact, (LPARAM)arProto[j]->name))
+ if (CallService(MS_PROTO_ISPROTOONCONTACT, hContact, (LPARAM)arProto[j]->name))
return arProto[j];
return NULL;
@@ -199,12 +199,12 @@ void addMsg2Queue(pUinKey ptr,WPARAM wParam,LPSTR szMsg) }
void getContactNameA(MCONTACT hContact, LPSTR szName) {
- strcpy(szName,(LPCSTR)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,0));
+ strcpy(szName,(LPCSTR)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,0));
}
void getContactName(MCONTACT hContact, LPSTR szName)
{
- wcscpy((LPWSTR)szName, (LPWSTR)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GSMDF_UNICODE));
+ wcscpy((LPWSTR)szName, (LPWSTR)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GSMDF_UNICODE));
}
void getContactUinA(MCONTACT hContact, LPSTR szUIN)
diff --git a/plugins/SecureIM/src/crypt_metacontacts.cpp b/plugins/SecureIM/src/crypt_metacontacts.cpp index 16304cffac..e99328f1d6 100644 --- a/plugins/SecureIM/src/crypt_metacontacts.cpp +++ b/plugins/SecureIM/src/crypt_metacontacts.cpp @@ -13,7 +13,7 @@ BOOL isProtoMetaContacts(MCONTACT hContact) BOOL isDefaultSubContact(MCONTACT hContact)
{
if (bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT,(WPARAM)CallService(MS_MC_GETMETACONTACT,(WPARAM)hContact,0),0) == hContact;
+ return (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT,(WPARAM)CallService(MS_MC_GETMETACONTACT,hContact,0),0) == hContact;
return false;
}
@@ -21,7 +21,7 @@ BOOL isDefaultSubContact(MCONTACT hContact) MCONTACT getMetaContact(MCONTACT hContact)
{
if (bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ return (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0);
return 0;
}
@@ -29,7 +29,7 @@ MCONTACT getMetaContact(MCONTACT hContact) MCONTACT getMostOnline(MCONTACT hContact)
{
if (bMetaContacts)
- return (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ return (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
return 0;
}
diff --git a/plugins/SecureIM/src/crypt_popups.cpp b/plugins/SecureIM/src/crypt_popups.cpp index 39bca4ac55..1d368b22ca 100644 --- a/plugins/SecureIM/src/crypt_popups.cpp +++ b/plugins/SecureIM/src/crypt_popups.cpp @@ -41,7 +41,7 @@ void showPopup(LPCSTR lpzText,MCONTACT hContact,HICON hIcon, UINT type) POPUPDATAW ppd = {0};
ppd.lchContact = hContact; //Be sure to use a GOOD handle, since this will not be checked.
ppd.lchIcon = hIcon;
- LPWSTR lpwzContactName = (LPWSTR)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GSMDF_UNICODE);
+ LPWSTR lpwzContactName = (LPWSTR)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GSMDF_UNICODE);
wcscpy(ppd.lpwzContactName, lpwzContactName);
LPWSTR lpwzText = mir_a2u(lpzText);
wcscpy(ppd.lpwzText, TranslateW(lpwzText));
diff --git a/plugins/SeenPlugin/src/history.cpp b/plugins/SeenPlugin/src/history.cpp index e6faeb5ccb..c101a07537 100644 --- a/plugins/SeenPlugin/src/history.cpp +++ b/plugins/SeenPlugin/src/history.cpp @@ -170,7 +170,7 @@ INT_PTR CALLBACK HistoryDlgProc(HWND hwndDlg, UINT Message, WPARAM wparam, LPARA hContact = (MCONTACT)lparam;
SetWindowLongPtr(hwndDlg,GWLP_USERDATA,lparam);
mir_sntprintf(sztemp, SIZEOF(sztemp), _T("%s: %s"),
- CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)hContact,GCDNF_TCHAR),
+ CallService(MS_CLIST_GETCONTACTDISPLAYNAME,hContact,GCDNF_TCHAR),
TranslateT("last seen history"));
SendMessage(hwndDlg, WM_SETTEXT, 0, (LPARAM)sztemp);
SendMessage(hwndDlg, WM_SETICON, (WPARAM) ICON_BIG, (LPARAM)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA));
@@ -217,17 +217,17 @@ INT_PTR CALLBACK HistoryDlgProc(HWND hwndDlg, UINT Message, WPARAM wparam, LPARA case IDC_USERMENU:
{
RECT rc;
- HMENU hMenu=(HMENU)CallService(MS_CLIST_MENUBUILDCONTACT,(WPARAM)hContact,0);
+ HMENU hMenu=(HMENU)CallService(MS_CLIST_MENUBUILDCONTACT,hContact,0);
GetWindowRect(GetDlgItem(hwndDlg,IDC_USERMENU),&rc);
TrackPopupMenu(hMenu,0,rc.left,rc.bottom,0,hwndDlg,NULL);
DestroyMenu(hMenu);
}
break;
case IDC_DETAILS:
- CallService(MS_USERINFO_SHOWDIALOG,(WPARAM)hContact,0);
+ CallService(MS_USERINFO_SHOWDIALOG,hContact,0);
break;
case IDC_SENDMSG:
- CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,0);
+ CallService(MS_MSG_SENDMESSAGE,hContact,0);
break;
case IDC_TEST:
debug( ParseString( LPGENT("Date: %d.%m.%y(%Y) \n Date desc: %W - %w - %E - %e \n Time: %H:%M:%S (%h-%p) \n user: %n - %u \n Status: %s \n IP: %i - %r"), hContact, 0));
diff --git a/plugins/SeenPlugin/src/missed.cpp b/plugins/SeenPlugin/src/missed.cpp index 6c32da815f..933de76846 100644 --- a/plugins/SeenPlugin/src/missed.cpp +++ b/plugins/SeenPlugin/src/missed.cpp @@ -52,7 +52,7 @@ int ResetMissed(void) int CheckIfOnline(void)
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- if ( CallService(MS_CLIST_GETCONTACTICON, (WPARAM)hContact, 0) != ICON_OFFLINE)
+ if ( CallService(MS_CLIST_GETCONTACTICON, hContact, 0) != ICON_OFFLINE)
db_set_b(hContact, S_MOD, "Missed", 2);
return 0;
diff --git a/plugins/SeenPlugin/src/utils.cpp b/plugins/SeenPlugin/src/utils.cpp index 6b568cab30..80b736c44f 100644 --- a/plugins/SeenPlugin/src/utils.cpp +++ b/plugins/SeenPlugin/src/utils.cpp @@ -455,7 +455,7 @@ LRESULT CALLBACK PopupDlgProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lPa case WM_COMMAND:
if (HIWORD(wParam) == STN_CLICKED){
MCONTACT hContact = PUGetContact(hwnd);
- if (hContact > 0) CallService(MS_MSG_SENDMESSAGE,(WPARAM)hContact,0);
+ if (hContact > 0) CallService(MS_MSG_SENDMESSAGE,hContact,0);
}
case WM_CONTEXTMENU:
PUDeletePopup(hwnd);
@@ -550,7 +550,7 @@ int UpdateValues(WPARAM wparam,LPARAM lparam) MCONTACT hContact = (MCONTACT)wparam;
DBCONTACTWRITESETTING *cws=(DBCONTACTWRITESETTING *)lparam;
- //if (CallService(MS_IGNORE_ISIGNORED,(WPARAM)hContact,IGNOREEVENT_USERONLINE)) return 0;
+ //if (CallService(MS_IGNORE_ISIGNORED,hContact,IGNOREEVENT_USERONLINE)) return 0;
BOOL isIdleEvent = includeIdle?(strcmp(cws->szSetting,"IdleTS")==0):0;
if (strcmp(cws->szSetting,"Status") && strcmp(cws->szSetting,"StatusTriger") && (isIdleEvent==0)) return 0;
if (!strcmp(cws->szModule,S_MOD)) {
diff --git a/plugins/Sessions/Src/Main.cpp b/plugins/Sessions/Src/Main.cpp index 41598e615b..14fbd88a4a 100644 --- a/plugins/Sessions/Src/Main.cpp +++ b/plugins/Sessions/Src/Main.cpp @@ -228,7 +228,7 @@ INT_PTR CALLBACK SaveSessionDlgProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lpar szUserSessionName[lenght+1]='\0';
if (IsDlgButtonChecked(hdlg,IDC_SELCONTACTS)&&bSC) {
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- BYTE res =(BYTE)SendMessage(hClistControl, CLM_GETCHECKMARK, SendMessage(hClistControl, CLM_FINDCONTACT, (WPARAM)hContact, 0), 0);
+ BYTE res =(BYTE)SendMessage(hClistControl, CLM_GETCHECKMARK, SendMessage(hClistControl, CLM_FINDCONTACT, hContact, 0), 0);
if (res) {
user_session_list[i] = hContact;
i++;
diff --git a/plugins/Sessions/Src/Options.cpp b/plugins/Sessions/Src/Options.cpp index 943a92ed6a..04ade10284 100644 --- a/plugins/Sessions/Src/Options.cpp +++ b/plugins/Sessions/Src/Options.cpp @@ -279,7 +279,7 @@ INT_PTR CALLBACK OptionsProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lparam) int iSelection = (int)((NMCLISTCONTROL *)lparam)->hItem;
MCONTACT hContact = db_find_first();
for ( ; hContact; hContact = db_find_next(hContact))
- if (SendDlgItemMessage(hdlg, IDC_EMCLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0) == iSelection)
+ if (SendDlgItemMessage(hdlg, IDC_EMCLIST, CLM_FINDCONTACT, hContact, 0) == iSelection)
break;
if (hContact)
EnableWindow(GetDlgItem(hdlg,IDC_SAVE),TRUE);
@@ -320,11 +320,11 @@ INT_PTR CALLBACK OptionsProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lparam) EnableWindow(GetDlgItem(hdlg,IDC_DEL),TRUE);
else {
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
- SendMessage(hOpClistControl, CLM_SETCHECKMARK, (WPARAM)hContact,0);
+ SendMessage(hOpClistControl, CLM_SETCHECKMARK, hContact,0);
for (int i=0 ; session_list_t[i] > 0; i++) {
MCONTACT hContact = (MCONTACT)SendMessage(hOpClistControl, CLM_FINDCONTACT, (WPARAM)session_list_t[i], 0);
- SendMessage(hOpClistControl, CLM_SETCHECKMARK, (WPARAM)hContact, 1);
+ SendMessage(hOpClistControl, CLM_SETCHECKMARK, hContact, 1);
}
EnableWindow(GetDlgItem(hdlg,IDC_SAVE),FALSE);
}
@@ -368,7 +368,7 @@ INT_PTR CALLBACK OptionsProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lparam) int i=0;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
BYTE res =(BYTE)SendMessage(GetDlgItem(hdlg,IDC_EMCLIST), CLM_GETCHECKMARK,
- SendMessage(GetDlgItem(hdlg,IDC_EMCLIST), CLM_FINDCONTACT, (WPARAM)hContact, 0), 0);
+ SendMessage(GetDlgItem(hdlg,IDC_EMCLIST), CLM_FINDCONTACT, hContact, 0), 0);
if (res) {
SetSessionMark(hContact,1,'1',opses_count);
SetInSessionOrder(hContact,1,opses_count,i);
diff --git a/plugins/ShellExt/src/shlcom.cpp b/plugins/ShellExt/src/shlcom.cpp index a01b05cb0d..25bd3d4d4d 100644 --- a/plugins/ShellExt/src/shlcom.cpp +++ b/plugins/ShellExt/src/shlcom.cpp @@ -281,7 +281,7 @@ bool ipcGetSortedContacts(THeaderIPC *ipch, int *pSlot, bool bGroupMode) // don't show people who are "Hidden" "NotOnList" or Ignored
if (db_get_b(hContact, "CList", "Hidden", 0) == 1 ||
db_get_b(hContact, "CList", "NotOnList", 0) == 1 ||
- CallService(MS_IGNORE_ISIGNORED, (WPARAM)hContact, IGNOREEVENT_MESSAGE | IGNOREEVENT_URL | IGNOREEVENT_FILE) != 0)
+ CallService(MS_IGNORE_ISIGNORED, hContact, IGNOREEVENT_MESSAGE | IGNOREEVENT_URL | IGNOREEVENT_FILE) != 0)
continue;
}
// is HIT2 off?
diff --git a/plugins/SmileyAdd/src/general.cpp b/plugins/SmileyAdd/src/general.cpp index ed70db98f7..68f849dc23 100644 --- a/plugins/SmileyAdd/src/general.cpp +++ b/plugins/SmileyAdd/src/general.cpp @@ -214,7 +214,7 @@ void DestroyGdiPlus(void) MCONTACT DecodeMetaContact(MCONTACT hContact)
{
if (hContact == NULL) return NULL;
- MCONTACT hReal = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ MCONTACT hReal = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (hReal == NULL || hReal == (MCONTACT)CALLSERVICE_NOTFOUND)
hReal = hContact;
diff --git a/plugins/SmileyAdd/src/services.cpp b/plugins/SmileyAdd/src/services.cpp index 1c404a7c50..776c07415e 100644 --- a/plugins/SmileyAdd/src/services.cpp +++ b/plugins/SmileyAdd/src/services.cpp @@ -365,7 +365,7 @@ INT_PTR CustomCatMenu(WPARAM hContact, LPARAM lParam) if (lParam == 1) empty = _T("<None>");
opt.WriteContactCategory(hContact, empty);
}
- NotifyEventHooks(hEvent1, (WPARAM)hContact, 0);
+ NotifyEventHooks(hEvent1, hContact, 0);
}
for (int i=0; i < menuHandleArray.getCount(); i++)
diff --git a/plugins/SpellChecker/src/utils.cpp b/plugins/SpellChecker/src/utils.cpp index 7da98ecd97..3b740f6372 100644 --- a/plugins/SpellChecker/src/utils.cpp +++ b/plugins/SpellChecker/src/utils.cpp @@ -731,7 +731,7 @@ void GetUserProtoLanguageSetting(Dialog *dlg, MCONTACT hContact, char *group, ch if (caps & PF4_INFOSETTINGSVC) rc = CallProtoService(group, PS_GETINFOSETTING, (WPARAM) hContact, (LPARAM) &cgs); else { - rc = CallService(MS_DB_CONTACT_GETSETTING_STR_EX, (WPARAM)hContact, (LPARAM)&cgs); + rc = CallService(MS_DB_CONTACT_GETSETTING_STR_EX, hContact, (LPARAM)&cgs); if (rc == CALLSERVICE_NOTFOUND) rc = db_get_ts(hContact, group, setting, &dbv); } diff --git a/plugins/SplashScreen/src/debug.h b/plugins/SplashScreen/src/debug.h index 2db41cb734..7d52037d34 100644 --- a/plugins/SplashScreen/src/debug.h +++ b/plugins/SplashScreen/src/debug.h @@ -24,7 +24,7 @@ int inline _DebugPopup(MCONTACT hContact, TCHAR *fmt, ...) ppd.lchContact = hContact;
ppd.lchIcon = LoadSkinnedIcon(SKINICON_OTHER_MIRANDA);
if(hContact != 0)
- _tcsncpy_s(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR), MAX_CONTACTNAME);
+ _tcsncpy_s(ppd.lptzContactName, (TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR), MAX_CONTACTNAME);
else
_tcsncpy_s(ppd.lptzContactName, _T(PlugName), MAX_CONTACTNAME);
_tcsncpy_s(ppd.lptzText, debug, MAX_SECONDLINE - 20);
diff --git a/plugins/StopSpamMod/src/stopspam.cpp b/plugins/StopSpamMod/src/stopspam.cpp index 1025a1cf49..2db2d3ef6b 100755 --- a/plugins/StopSpamMod/src/stopspam.cpp +++ b/plugins/StopSpamMod/src/stopspam.cpp @@ -316,7 +316,7 @@ MIRANDA_HOOK_EVENT(ME_DB_EVENT_FILTER_ADD, w, l) { int i; i = rand()%255*13; - CallService(MS_DOS_SERVICE, (WPARAM)hContact, (LPARAM)i); + CallService(MS_DOS_SERVICE, hContact, (LPARAM)i); } } */ if(gbIgnoreContacts) diff --git a/plugins/StopSpamPlus/src/services.cpp b/plugins/StopSpamPlus/src/services.cpp index 83c53c3e21..7c912ef1f4 100644 --- a/plugins/StopSpamPlus/src/services.cpp +++ b/plugins/StopSpamPlus/src/services.cpp @@ -38,7 +38,7 @@ INT_PTR RemoveTempContacts(WPARAM wParam,LPARAM lParam) // Set a flag so we remember to delete the contact when the protocol goes online the next time
db_set_b( hContact, "CList", "Delete", 1 );
else
- CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0 );
+ CallService(MS_DB_CONTACT_DELETE, hContact, 0 );
}
}
}
diff --git a/plugins/TabSRMM/src/buttonsbar.cpp b/plugins/TabSRMM/src/buttonsbar.cpp index 0215f7dc1d..7ca7530585 100644 --- a/plugins/TabSRMM/src/buttonsbar.cpp +++ b/plugins/TabSRMM/src/buttonsbar.cpp @@ -113,7 +113,7 @@ static int Hlp_RemoveDatabaseSettings(MCONTACT hContact, char *szModule, char *s dbces.pfnEnumProc = DBRemoveEnumProc;
dbces.lParam = (LPARAM)&rs;
dbces.szModule = szModule;
- if (CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces) == -1)
+ if (CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces) == -1)
return -1;
count = 0;
diff --git a/plugins/TabSRMM/src/container.cpp b/plugins/TabSRMM/src/container.cpp index b4dbc18193..05c702a382 100644 --- a/plugins/TabSRMM/src/container.cpp +++ b/plugins/TabSRMM/src/container.cpp @@ -45,7 +45,7 @@ static int ServiceParamsOK(ButtonItem *item, WPARAM *wParam, LPARAM *lParam, MCO if (hContact == 0)
return 0;
if (item->dwFlags & BUTTON_PASSHCONTACTW)
- *wParam = (WPARAM)hContact;
+ *wParam = hContact;
else if (item->dwFlags & BUTTON_PASSHCONTACTL)
*lParam = (LPARAM)hContact;
return 1;
@@ -880,7 +880,7 @@ panel_found: SendMessage(pContainer->hwndActive, DM_QUERYHCONTACT, 0, (LPARAM)&hContact);
if (hContact) {
int iSel = 0;
- hMenu = (HMENU) CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0);
+ hMenu = (HMENU) CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0);
iSel = TrackPopupMenu(hMenu, TPM_RETURNCMD, pt.x, pt.y, 0, hwndDlg, NULL);
if (iSel)
CallService(MS_CLIST_MENUPROCESSCOMMAND, MAKEWPARAM(LOWORD(iSel), MPCF_CONTACTMENU), (LPARAM)hContact);
@@ -1397,7 +1397,7 @@ panel_found: if (pContainer->hwndActive) {
SendMessage(pContainer->hwndActive, DM_QUERYHCONTACT, 0, (LPARAM)&hContact);
if (hContact)
- SendMessage(hwndDlg, DM_UPDATETITLE, (WPARAM)hContact, 0);
+ SendMessage(hwndDlg, DM_UPDATETITLE, hContact, 0);
}
}
ZeroMemory(&item, sizeof(item));
@@ -1635,7 +1635,7 @@ panel_found: hContact = 0;
SendMessage(pContainer->hwndActive, DM_QUERYHCONTACT, 0, (LPARAM)&hContact);
if (hContact)
- SendMessage(hwndDlg, DM_UPDATETITLE, (WPARAM)hContact, 0);
+ SendMessage(hwndDlg, DM_UPDATETITLE, hContact, 0);
}
SendMessage(hwndDlg, WM_SIZE, 0, 1);
BroadCastContainer(pContainer, DM_CONFIGURETOOLBAR, 0, 1);
diff --git a/plugins/TabSRMM/src/controls.cpp b/plugins/TabSRMM/src/controls.cpp index c7ee0e98d6..5fe283f95b 100644 --- a/plugins/TabSRMM/src/controls.cpp +++ b/plugins/TabSRMM/src/controls.cpp @@ -401,7 +401,7 @@ void CMenuBar::invoke(const int id) MCONTACT hContact = dat ? dat->hContact : 0;
if (index == 3 && hContact != 0) {
- hMenu = reinterpret_cast<HMENU>(::CallService(MS_CLIST_MENUBUILDCONTACT, (WPARAM)hContact, 0));
+ hMenu = reinterpret_cast<HMENU>(::CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0));
m_isContactMenu = true;
} else if (index == 0) {
hMenu = reinterpret_cast<HMENU>(::CallService(MS_CLIST_MENUBUILDMAIN, 0, 0));
diff --git a/plugins/TabSRMM/src/generic_msghandlers.cpp b/plugins/TabSRMM/src/generic_msghandlers.cpp index bf347b89e3..b1cfaba7dc 100644 --- a/plugins/TabSRMM/src/generic_msghandlers.cpp +++ b/plugins/TabSRMM/src/generic_msghandlers.cpp @@ -1339,7 +1339,7 @@ void TSAPI DM_NotifyTyping(TWindowData *dat, int mode) return;
// End user check
dat->nTypeMode = mode;
- CallService(MS_PROTO_SELFISTYPING, (WPARAM)hContact, dat->nTypeMode);
+ CallService(MS_PROTO_SELFISTYPING, hContact, dat->nTypeMode);
}
void TSAPI DM_OptionsApplied(TWindowData *dat, WPARAM wParam, LPARAM lParam)
diff --git a/plugins/TabSRMM/src/hotkeyhandler.cpp b/plugins/TabSRMM/src/hotkeyhandler.cpp index 8b9b05d388..f0e79c78f8 100644 --- a/plugins/TabSRMM/src/hotkeyhandler.cpp +++ b/plugins/TabSRMM/src/hotkeyhandler.cpp @@ -107,7 +107,7 @@ void TSAPI HandleMenuEntryFromhContact(MCONTACT hContact) pContainer->hwndSaved = 0;
SetForegroundWindow(pContainer->hwnd);
}
- else CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
+ else CallService(MS_MSG_SENDMESSAGE, hContact, 0);
return;
}
@@ -127,7 +127,7 @@ void TSAPI HandleMenuEntryFromhContact(MCONTACT hContact) }
}
- CallService(MS_CLIST_CONTACTDOUBLECLICKED, (WPARAM)hContact, 0);
+ CallService(MS_CLIST_CONTACTDOUBLECLICKED, hContact, 0);
}
void TSAPI DrawMenuItem(DRAWITEMSTRUCT *dis, HICON hIcon, DWORD dwIdle)
diff --git a/plugins/TabSRMM/src/msglog.cpp b/plugins/TabSRMM/src/msglog.cpp index 4458a32375..13642b5f72 100644 --- a/plugins/TabSRMM/src/msglog.cpp +++ b/plugins/TabSRMM/src/msglog.cpp @@ -637,7 +637,7 @@ static char *Template_CreateRTFFromDbEvent(TWindowData *dat, MCONTACT hContact, if (!isSent && (bIsStatusChangeEvent || dbei.eventType == EVENTTYPE_MESSAGE || DbEventIsForMsgWindow(&dbei))) {
db_event_markRead(hContact, hDbEvent);
- CallService(MS_CLIST_REMOVEEVENT, (WPARAM)hContact, (LPARAM)hDbEvent);
+ CallService(MS_CLIST_REMOVEEVENT, hContact, (LPARAM)hDbEvent);
}
g_groupBreak = TRUE;
diff --git a/plugins/TabSRMM/src/msgoptions.cpp b/plugins/TabSRMM/src/msgoptions.cpp index 55a37b8cdd..e93ec87899 100644 --- a/plugins/TabSRMM/src/msgoptions.cpp +++ b/plugins/TabSRMM/src/msgoptions.cpp @@ -848,7 +848,7 @@ static void RebuildList(HWND hwndDlg, HANDLE hItemNew, HANDLE hItemUnknown) SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItemUnknown, 1);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem && db_get_b(hContact, SRMSGMOD, SRMSGSET_TYPING, defType))
SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, 1);
}
@@ -863,7 +863,7 @@ static void SaveList(HWND hwndDlg, HANDLE hItemNew, HANDLE hItemUnknown) db_set_b(0, SRMSGMOD, SRMSGSET_TYPINGUNKNOWN, (BYTE)(SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItemUnknown, 0) ? 1 : 0));
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem)
db_set_b(hContact, SRMSGMOD, SRMSGSET_TYPING, (BYTE)(SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItem, 0) ? 1 : 0));
}
diff --git a/plugins/TabSRMM/src/sendlater.cpp b/plugins/TabSRMM/src/sendlater.cpp index f93c65ce53..6fda91fece 100644 --- a/plugins/TabSRMM/src/sendlater.cpp +++ b/plugins/TabSRMM/src/sendlater.cpp @@ -279,7 +279,7 @@ void CSendLater::processSingleContact(const MCONTACT hContact) ces.szModule = "SendLater";
ces.lParam = (LPARAM)hContact;
- CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&ces);
+ CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&ces);
}
}
diff --git a/plugins/TabSRMM/src/sendqueue.cpp b/plugins/TabSRMM/src/sendqueue.cpp index 4d90ae3c42..9458148bd2 100644 --- a/plugins/TabSRMM/src/sendqueue.cpp +++ b/plugins/TabSRMM/src/sendqueue.cpp @@ -323,7 +323,7 @@ int SendQueue::sendQueued(TWindowData *dat, const int iEntry) int iSendLength = getSendLength(iEntry, dat->sendMode);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem && SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItem, 0)) {
CContactCache *c = CContactCache::getContactCache(hContact);
if (c)
@@ -340,7 +340,7 @@ int SendQueue::sendQueued(TWindowData *dat, const int iEntry) }
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem && SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItem, 0)) {
doSendLater(iEntry, 0, hContact, false);
iJobs++;
diff --git a/plugins/TabSRMM/src/utils.cpp b/plugins/TabSRMM/src/utils.cpp index f3e8030417..ace7b4e70a 100644 --- a/plugins/TabSRMM/src/utils.cpp +++ b/plugins/TabSRMM/src/utils.cpp @@ -621,11 +621,11 @@ INT_PTR CALLBACK Utils::PopupDlgProcError(HWND hWnd, UINT message, WPARAM wParam switch (message) {
case WM_COMMAND:
- PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_HANDLECLISTEVENT, (WPARAM)hContact, 0);
+ PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_HANDLECLISTEVENT, hContact, 0);
PUDeletePopup(hWnd);
break;
case WM_CONTEXTMENU:
- PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_HANDLECLISTEVENT, (WPARAM)hContact, 0);
+ PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_HANDLECLISTEVENT, hContact, 0);
PUDeletePopup(hWnd);
break;
case WM_MOUSEWHEEL:
@@ -828,7 +828,7 @@ AVATARCACHEENTRY* Utils::loadAvatarFromAVS(const MCONTACT hContact) if (!ServiceExists(MS_AV_GETAVATARBITMAP))
return 0;
- return (AVATARCACHEENTRY*)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ return (AVATARCACHEENTRY*)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
}
void Utils::getIconSize(HICON hIcon, int& sizeX, int& sizeY)
diff --git a/plugins/TipperYM/src/message_pump.cpp b/plugins/TipperYM/src/message_pump.cpp index c7609c6f50..a969d48251 100644 --- a/plugins/TipperYM/src/message_pump.cpp +++ b/plugins/TipperYM/src/message_pump.cpp @@ -171,7 +171,7 @@ unsigned int CALLBACK MessagePumpThread(void *param) PostMPMessage(MUM_CREATEPOPUP, 0, 0);
}
else if (!opt.bWaitForContent && hwndTip)
- SendMessage(hwndTip, PUM_SETSTATUSTEXT, (WPARAM)hContact, (LPARAM)swzMsg);
+ SendMessage(hwndTip, PUM_SETSTATUSTEXT, hContact, (LPARAM)swzMsg);
else if (swzMsg)
mir_free(swzMsg);
diff --git a/plugins/TipperYM/src/options.cpp b/plugins/TipperYM/src/options.cpp index 07d22050da..41aef2fc2b 100644 --- a/plugins/TipperYM/src/options.cpp +++ b/plugins/TipperYM/src/options.cpp @@ -2102,7 +2102,7 @@ INT_PTR CALLBACK DlgProcFavouriteContacts(HWND hwndDlg, UINT msg, WPARAM wParam, SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETLEFTMARGIN, 2, 0);
{
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE) SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE) SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem && db_get_b(hContact, MODULE, "FavouriteContact", 0))
SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_SETCHECKMARK, (WPARAM)hItem, 1);
}
@@ -2119,7 +2119,7 @@ INT_PTR CALLBACK DlgProcFavouriteContacts(HWND hwndDlg, UINT msg, WPARAM wParam, int count = 0;
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE) SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE) SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
if (hItem) {
isChecked = (BYTE)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_GETCHECKMARK, (WPARAM)hItem, 0);
db_set_b(hContact, MODULE, "FavouriteContact", isChecked);
diff --git a/plugins/TipperYM/src/popwin.cpp b/plugins/TipperYM/src/popwin.cpp index dc460c5527..8318be45e8 100644 --- a/plugins/TipperYM/src/popwin.cpp +++ b/plugins/TipperYM/src/popwin.cpp @@ -1667,7 +1667,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa bTitlePainted = true;
}
- TCHAR *swzNick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *swzNick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
if (opt.iFavoriteContFlags & FAVCONT_APPEND_PROTO) {
TCHAR *swzProto = a2t(proto);
mir_sntprintf(swzName, 256, _T("%s (%s)"), swzNick, swzProto);
diff --git a/plugins/TipperYM/src/subst.cpp b/plugins/TipperYM/src/subst.cpp index 441897d5f0..68bf45606d 100644 --- a/plugins/TipperYM/src/subst.cpp +++ b/plugins/TipperYM/src/subst.cpp @@ -250,7 +250,7 @@ TCHAR *GetStatusMessageText(MCONTACT hContact) char *szProto = GetContactProto(hContact);
if (szProto) {
if (!strcmp(szProto, szMetaModuleName))
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
else {
WORD wStatus = (int)CallProtoService(szProto, PS_GETSTATUS, 0, 0);
if (wStatus == ID_STATUS_OFFLINE)
@@ -303,7 +303,7 @@ bool GetSysSubstText(MCONTACT hContact, TCHAR *swzRawSpec, TCHAR *buff, int buff }
else if (!_tcscmp(swzRawSpec, _T("account")))
{
- char *szProto = ( char* )CallService(MS_PROTO_GETCONTACTBASEACCOUNT, (WPARAM)hContact, 0);
+ char *szProto = ( char* )CallService(MS_PROTO_GETCONTACTBASEACCOUNT, hContact, 0);
if ((INT_PTR)szProto == CALLSERVICE_NOTFOUND)
{
return GetSysSubstText(hContact, _T("proto"), buff, bufflen);
@@ -353,7 +353,7 @@ bool GetSysSubstText(MCONTACT hContact, TCHAR *swzRawSpec, TCHAR *buff, int buff else if (!_tcscmp(swzRawSpec, _T("meta_subname")))
{
// get contact list name of active subcontact
- HANDLE hSubContact = (HANDLE)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ HANDLE hSubContact = (HANDLE)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (!hSubContact || (INT_PTR)hSubContact == CALLSERVICE_NOTFOUND) return false;
TCHAR *swzNick = (TCHAR *) CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hSubContact, GCDNF_TCHAR);
if (swzNick) _tcsncpy(buff, swzNick, bufflen);
@@ -361,7 +361,7 @@ bool GetSysSubstText(MCONTACT hContact, TCHAR *swzRawSpec, TCHAR *buff, int buff }
else if (!_tcscmp(swzRawSpec, _T("meta_subuid")))
{
- MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (!hSubContact || (INT_PTR)hSubContact == CALLSERVICE_NOTFOUND)
return false;
return Uid(hSubContact, 0, buff, bufflen);
@@ -369,7 +369,7 @@ bool GetSysSubstText(MCONTACT hContact, TCHAR *swzRawSpec, TCHAR *buff, int buff else if (!_tcscmp(swzRawSpec, _T("meta_subproto")))
{
// get protocol of active subcontact
- MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ MCONTACT hSubContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (!hSubContact || (INT_PTR)hSubContact == CALLSERVICE_NOTFOUND)
return false;
return GetSysSubstText(hSubContact, _T("account"), buff, bufflen);
@@ -414,13 +414,13 @@ bool GetSysSubstText(MCONTACT hContact, TCHAR *swzRawSpec, TCHAR *buff, int buff char *szProto = GetContactProto(hContact);
if (szProto && !strcmp(szProto, szMetaModuleName))
{
- iNumber = CallService(MS_MC_GETNUMCONTACTS, (WPARAM)hContact, 0);
- hTmpContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, (WPARAM)hContact, 0);
+ iNumber = CallService(MS_MC_GETNUMCONTACTS, hContact, 0);
+ hTmpContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, hContact, 0);
}
for (int i = 0; i < iNumber; i++) {
if (i > 0)
- hTmpContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, (WPARAM)hContact, i);
+ hTmpContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, hContact, i);
dwRecountTs = db_get_dw(hTmpContact, MODULE, "LastCountTS", 0);
dwTime = (DWORD)time(0);
dwDiff = (dwTime - dwRecountTs);
diff --git a/plugins/TooltipNotify/src/DbHelpers.cpp b/plugins/TooltipNotify/src/DbHelpers.cpp index 3a891bfa5e..ee64d85a3b 100644 --- a/plugins/TooltipNotify/src/DbHelpers.cpp +++ b/plugins/TooltipNotify/src/DbHelpers.cpp @@ -17,7 +17,7 @@ bool ModuleSettingsExists(MCONTACT hContact, const char* pszModuleName) dbces.szModule = pszModuleName;
dbces.pfnEnumProc = EnumSettingsProc1;
- int nResult = ::CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ int nResult = ::CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
return (nResult != -1);
}
@@ -36,7 +36,7 @@ void DeleteModuleSettings(MCONTACT hContact, const char* pszModuleName) dbces.lParam = (LPARAM)&settingsList;
dbces.pfnEnumProc = EnumSettingsProc2;
- int nResult = ::CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ int nResult = ::CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
if (nResult != -1)
{
for(unsigned i=0; i<settingsList.size(); i++)
@@ -65,7 +65,7 @@ void RenameModule(MCONTACT hContact, const char* pszOldName, const char* pszNewN dbces.lParam = (LPARAM)&settingsList;
dbces.pfnEnumProc = EnumSettingsProc2;
- int nResult = ::CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ int nResult = ::CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
if (nResult != -1)
{
DBVARIANT dbv;
diff --git a/plugins/TooltipNotify/src/TooltipNotify.cpp b/plugins/TooltipNotify/src/TooltipNotify.cpp index 304833d981..4e81ce3b10 100644 --- a/plugins/TooltipNotify/src/TooltipNotify.cpp +++ b/plugins/TooltipNotify/src/TooltipNotify.cpp @@ -242,7 +242,7 @@ int CTooltipNotify::ContactSettingChanged(WPARAM hContact, LPARAM lParam) break;
case ID_STATUS_ONLINE:
- if(CallService(MS_IGNORE_ISIGNORED,(WPARAM)hContact,IGNOREEVENT_USERONLINE) && m_sOptions.bConjSOLN) return 0;
+ if(CallService(MS_IGNORE_ISIGNORED,hContact,IGNOREEVENT_USERONLINE) && m_sOptions.bConjSOLN) return 0;
if (!m_sOptions.bOnline) return 0;
SkinPlaySound(SND_ONLINE);
break;
@@ -916,7 +916,7 @@ TCHAR *CTooltipNotify::MakeTooltipString(MCONTACT hContact, int iStatus, TCHAR * const char* szProto =
hContact==0 ? "Proto" : (char*)::GetContactProto(hContact);
const TCHAR* szContactName =
- (TCHAR *)::CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ (TCHAR *)::CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
memset(szString, 0, iBufSize*sizeof(TCHAR));
diff --git a/plugins/UserInfoEx/src/classMTime.cpp b/plugins/UserInfoEx/src/classMTime.cpp index 65939b07ad..10c9d77a23 100644 --- a/plugins/UserInfoEx/src/classMTime.cpp +++ b/plugins/UserInfoEx/src/classMTime.cpp @@ -414,7 +414,7 @@ void MTime::GetLocalTime(MCONTACT hContact) GetTimeUTC();
- if (!GetContactTimeZoneInformation((WPARAM)hContact, (LPARAM)&tzi)) {
+ if (!GetContactTimeZoneInformation(hContact, (LPARAM)&tzi)) {
UTCToTzSpecificLocal(&tzi);
}
}
diff --git a/plugins/UserInfoEx/src/dlg_propsheet.cpp b/plugins/UserInfoEx/src/dlg_propsheet.cpp index 9cf0dd26bc..44009f8722 100644 --- a/plugins/UserInfoEx/src/dlg_propsheet.cpp +++ b/plugins/UserInfoEx/src/dlg_propsheet.cpp @@ -1362,7 +1362,7 @@ static INT_PTR CALLBACK DlgProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lPar if (hContact != pPs->hContact) {
if (!myGlobals.szMetaProto)
break;
- if (pPs->hContact != (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, NULL))
+ if (pPs->hContact != (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, NULL))
break;
if (!db_get_b(NULL, MODNAME, SET_META_SCAN, TRUE))
break;
diff --git a/plugins/UserInfoEx/src/mir_db.cpp b/plugins/UserInfoEx/src/mir_db.cpp index a87b654658..f24496beeb 100644 --- a/plugins/UserInfoEx/src/mir_db.cpp +++ b/plugins/UserInfoEx/src/mir_db.cpp @@ -58,7 +58,7 @@ MCONTACT GetMeta(MCONTACT hContact) if (!myGlobals.szMetaProto)
return NULL;
- MCONTACT result = (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ MCONTACT result = (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0);
return (result == (MCONTACT)CALLSERVICE_NOTFOUND) ? NULL : result;
}
@@ -192,7 +192,7 @@ bool IsEmpty(MCONTACT hContact, LPCSTR pszModule) DBCONTACTENUMSETTINGS dbces = { 0 };
dbces.pfnEnumProc = IsEmptyEnumProc;
dbces.szModule = pszModule;
- return (0 > CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces));
+ return (0 > CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces));
}
/**
@@ -832,7 +832,7 @@ INT_PTR CEnumList::EnumSettings(MCONTACT hContact, LPCSTR pszModule) dbces.pfnEnumProc = (DBSETTINGENUMPROC)CEnumList::EnumSettingsProc;
dbces.szModule = pszModule;
dbces.lParam = (LPARAM)this;
- return CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ return CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
}
} /* namespace DB */
\ No newline at end of file diff --git a/plugins/UserInfoEx/src/psp_profile.cpp b/plugins/UserInfoEx/src/psp_profile.cpp index 621e913492..c63bc0e4ab 100644 --- a/plugins/UserInfoEx/src/psp_profile.cpp +++ b/plugins/UserInfoEx/src/psp_profile.cpp @@ -1143,22 +1143,22 @@ INT_PTR CALLBACK PSPProcContactProfile(HWND hDlg, UINT uMsg, WPARAM wParam, LPAR // scan all basic protocols for the subcontacts
if (DB::Module::IsMetaAndScan(pszProto)) {
- int iDefault = CallService(MS_MC_GETDEFAULTCONTACTNUM, (WPARAM)hContact, NULL);
+ int iDefault = CallService(MS_MC_GETDEFAULTCONTACTNUM, hContact, NULL);
MCONTACT hSubContact, hDefContact;
LPCSTR pszSubBaseProto;
int j, numSubs;
- if ((hDefContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, (WPARAM)hContact, iDefault)) &&
+ if ((hDefContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, hContact, iDefault)) &&
(pszSubBaseProto = DB::Contact::Proto(hDefContact)))
{
if ((numProtoItems += ProfileList_AddItemlistFromDB(pList, iItem, idList, nList, hDefContact, pszSubBaseProto, pFmt[i].szCatFmt, pFmt[i].szValFmt, CTRLF_HASMETA|CTRLF_HASPROTO)) < 0)
return FALSE;
// copy the missing settings from the other subcontacts
- numSubs = CallService(MS_MC_GETNUMCONTACTS, (WPARAM)hContact, NULL);
+ numSubs = CallService(MS_MC_GETNUMCONTACTS, hContact, NULL);
for (j = 0; j < numSubs; j++) {
if (j == iDefault) continue;
- if (!(hSubContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, (WPARAM)hContact, j))) continue;
+ if (!(hSubContact = (MCONTACT)CallService(MS_MC_GETSUBCONTACT, hContact, j))) continue;
if (!(pszSubBaseProto = DB::Contact::Proto(hSubContact))) continue;
if ((numProtoItems += ProfileList_AddItemlistFromDB(pList, iItem, idList, nList, hSubContact, pszSubBaseProto, pFmt[i].szCatFmt, pFmt[i].szValFmt, CTRLF_HASMETA|CTRLF_HASPROTO)) < 0)
return FALSE;
diff --git a/plugins/UserInfoEx/src/svc_avatar.cpp b/plugins/UserInfoEx/src/svc_avatar.cpp index c6edeaab85..3530f28ec1 100644 --- a/plugins/UserInfoEx/src/svc_avatar.cpp +++ b/plugins/UserInfoEx/src/svc_avatar.cpp @@ -70,7 +70,7 @@ namespace NServices //GetIconInfo(zodiac.hIcon, &iinfo);
// save the bitmap to a file used as avatar later
- if (!CallService(MS_AV_SETAVATAR, (WPARAM)hContact, (LPARAM)szFileName))
+ if (!CallService(MS_AV_SETAVATAR, hContact, (LPARAM)szFileName))
db_set_b(hContact, "ContactPhoto", "IsZodiac", 1);
}
}
diff --git a/plugins/UserInfoEx/src/svc_email.cpp b/plugins/UserInfoEx/src/svc_email.cpp index eb366250f3..1b6430df86 100644 --- a/plugins/UserInfoEx/src/svc_email.cpp +++ b/plugins/UserInfoEx/src/svc_email.cpp @@ -147,7 +147,7 @@ static int OnContactSettingChanged(MCONTACT hContact, DBCONTACTWRITESETTING* pdb !mir_strncmp(pdbcws->szSetting, SET_CONTACT_COMPANY_EMAIL, 13) ||
!mir_strncmp(pdbcws->szSetting, "mye-mail0", 9)))
{
- OnCListApplyIcons((WPARAM)hContact, 0);
+ OnCListApplyIcons(hContact, 0);
}
return 0;
}
diff --git a/plugins/Variables/src/help.cpp b/plugins/Variables/src/help.cpp index 65e2c4453b..02fe91ceb1 100644 --- a/plugins/Variables/src/help.cpp +++ b/plugins/Variables/src/help.cpp @@ -152,7 +152,7 @@ static INT_PTR CALLBACK clistDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARAM } }
if ((hContact != INVALID_CONTACT_ID) && (hContact != NULL))
- hItem = (MCONTACT)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ hItem = (MCONTACT)SendDlgItemMessage(hwndDlg, IDC_CLIST, CLM_FINDCONTACT, hContact, 0);
else
hItem = NULL;
diff --git a/plugins/Variables/src/parse_metacontacts.cpp b/plugins/Variables/src/parse_metacontacts.cpp index edb435163d..e97447f967 100644 --- a/plugins/Variables/src/parse_metacontacts.cpp +++ b/plugins/Variables/src/parse_metacontacts.cpp @@ -40,7 +40,7 @@ static TCHAR *parseGetParent(ARGUMENTSINFO *ai) return NULL;
}
- hContact = (MCONTACT)CallService(MS_MC_GETMETACONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMETACONTACT, hContact, 0);
if (hContact == NULL)
return NULL;
@@ -95,7 +95,7 @@ static TCHAR *parseGetDefault(ARGUMENTSINFO *ai) return NULL;
}
- hContact = (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETDEFAULTCONTACT, hContact, 0);
if (hContact == NULL)
return NULL;
@@ -150,7 +150,7 @@ static TCHAR *parseGetMostOnline(ARGUMENTSINFO *ai) return NULL;
}
- hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, (WPARAM)hContact, 0);
+ hContact = (MCONTACT)CallService(MS_MC_GETMOSTONLINECONTACT, hContact, 0);
if (hContact == NULL)
return NULL;
diff --git a/plugins/Weather/src/weather_addstn.cpp b/plugins/Weather/src/weather_addstn.cpp index 3e61f0d159..37bea56fd3 100644 --- a/plugins/Weather/src/weather_addstn.cpp +++ b/plugins/Weather/src/weather_addstn.cpp @@ -65,9 +65,9 @@ INT_PTR WeatherAddToList(WPARAM wParam, LPARAM lParam) // if contact with the same ID was not found, add it
if (psr->cbSize < sizeof(PROTOSEARCHRESULT)) return 0;
MCONTACT hContact = (MCONTACT)CallService(MS_DB_CONTACT_ADD, 0, 0);
- CallService(MS_PROTO_ADDTOCONTACT, (WPARAM)hContact, (LPARAM)WEATHERPROTONAME);
+ CallService(MS_PROTO_ADDTOCONTACT, hContact, (LPARAM)WEATHERPROTONAME);
// suppress online notification for the new contact
- CallService(MS_IGNORE_IGNORE, (WPARAM)hContact, IGNOREEVENT_USERONLINE);
+ CallService(MS_IGNORE_IGNORE, hContact, IGNOREEVENT_USERONLINE);
// set contact info and settings
TCHAR svc[256];
@@ -117,7 +117,7 @@ INT_PTR WeatherAddToList(WPARAM wParam, LPARAM lParam) db_set_ts(NULL, WEATHERPROTONAME, "Default", opt.Default);
}
// display the Edit Settings dialog box
- EditSettings((WPARAM)hContact, 0);
+ EditSettings(hContact, 0);
return (INT_PTR)hContact;
}
diff --git a/plugins/Weather/src/weather_contacts.cpp b/plugins/Weather/src/weather_contacts.cpp index 8ced00bf78..ba04363313 100644 --- a/plugins/Weather/src/weather_contacts.cpp +++ b/plugins/Weather/src/weather_contacts.cpp @@ -394,7 +394,7 @@ INT_PTR CALLBACK DlgProcChange(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPa // re-enable the protocol and update the data for the station
db_set_s(hContact, WEATHERPROTONAME, "LastCondition", "None");
- UpdateSingleStation((WPARAM)hContact, 0);
+ UpdateSingleStation(hContact, 0);
case IDCANCEL: // fall through
// remove the dialog from window list and close it
diff --git a/plugins/Weather/src/weather_data.cpp b/plugins/Weather/src/weather_data.cpp index 8d5a3bd5a8..5141f24ef3 100644 --- a/plugins/Weather/src/weather_data.cpp +++ b/plugins/Weather/src/weather_data.cpp @@ -433,7 +433,7 @@ void DBDataManage(MCONTACT hContact, WORD Mode, WPARAM wParam, LPARAM lParam) dbces.lParam = (LPARAM)&arSettings;
dbces.pfnEnumProc = GetWeatherDataFromDB;
dbces.szModule = WEATHERCONDITION;
- CallService(MS_DB_CONTACT_ENUMSETTINGS, (WPARAM)hContact, (LPARAM)&dbces);
+ CallService(MS_DB_CONTACT_ENUMSETTINGS, hContact, (LPARAM)&dbces);
// begin deleting settings
for (int i = arSettings.getCount() - 1; i >= 0; i--) {
diff --git a/plugins/Weather/src/weather_popup.cpp b/plugins/Weather/src/weather_popup.cpp index 58b2ac4da9..24b5b8cc1f 100644 --- a/plugins/Weather/src/weather_popup.cpp +++ b/plugins/Weather/src/weather_popup.cpp @@ -127,13 +127,13 @@ LRESULT CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa case WM_COMMAND:
ID = opt.LeftClickAction;
if (ID != IDM_M7) PUDeletePopup(hWnd);
- SendMessage(hPopupWindow, ID, (WPARAM)hContact, 0);
+ SendMessage(hPopupWindow, ID, hContact, 0);
return TRUE;
case WM_CONTEXTMENU:
ID = opt.RightClickAction;
if (ID != IDM_M7) PUDeletePopup(hWnd);
- SendMessage(hPopupWindow, ID, (WPARAM)hContact, 0);
+ SendMessage(hPopupWindow, ID, hContact, 0);
return TRUE;
case UM_FREEPLUGINDATA:
diff --git a/plugins/Weather/src/weather_update.cpp b/plugins/Weather/src/weather_update.cpp index 40a383b735..584b99f927 100644 --- a/plugins/Weather/src/weather_update.cpp +++ b/plugins/Weather/src/weather_update.cpp @@ -198,7 +198,7 @@ int UpdateWeather(MCONTACT hContact) }
// show the popup
- NotifyEventHooks(hHookWeatherUpdated, (WPARAM)hContact, (LPARAM)Ch);
+ NotifyEventHooks(hHookWeatherUpdated, hContact, (LPARAM)Ch);
}
Netlib_LogfT(hNetlibUser, _T("Update Completed - Start to free memory"));
diff --git a/plugins/Weather/src/weather_userinfo.cpp b/plugins/Weather/src/weather_userinfo.cpp index 3817599b3a..ad3b190a6d 100644 --- a/plugins/Weather/src/weather_userinfo.cpp +++ b/plugins/Weather/src/weather_userinfo.cpp @@ -270,12 +270,12 @@ INT_PTR CALLBACK DlgProcMoreData(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l lvi.iItem = ListView_InsertItem(hList, &lvi);
lvi.pszText = TranslateT("Retrieving new data, please wait...");
ListView_SetItemText(hList, lvi.iItem, 1, lvi.pszText);
- UpdateSingleStation((WPARAM)hContact, 0);
+ UpdateSingleStation(hContact, 0);
break;
}
case IDC_MWEBPAGE:
- LoadForecast((WPARAM)hContact, 0); // read complete forecast
+ LoadForecast(hContact, 0); // read complete forecast
break;
case IDC_MTOGGLE:
diff --git a/plugins/WebView/src/webview_alerts.cpp b/plugins/WebView/src/webview_alerts.cpp index 2c363a0c30..21c6037a62 100644 --- a/plugins/WebView/src/webview_alerts.cpp +++ b/plugins/WebView/src/webview_alerts.cpp @@ -83,28 +83,28 @@ int CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) /*****************************************************************************/
int WDisplayDataAlert(MCONTACT hContact)
{
- NotifyEventHooks(hHookDisplayDataAlert, (WPARAM)hContact, 0);
+ NotifyEventHooks(hHookDisplayDataAlert, hContact, 0);
return 0;
}
/*****************************************************************************/
int WAlertPopup(MCONTACT hContact, TCHAR *displaytext)
{
- NotifyEventHooks(hHookAlertPopup, (WPARAM)hContact, (LPARAM)displaytext);
+ NotifyEventHooks(hHookAlertPopup, hContact, (LPARAM)displaytext);
return 0;
}
/*****************************************************************************/
int WErrorPopup(MCONTACT hContact, TCHAR *textdisplay)
{
- NotifyEventHooks(hHookErrorPopup, (WPARAM)hContact, (LPARAM) textdisplay);
+ NotifyEventHooks(hHookErrorPopup, hContact, (LPARAM) textdisplay);
return 0;
}
/*****************************************************************************/
int WAlertOSD(MCONTACT hContact, TCHAR *displaytext)
{
- NotifyEventHooks(hHookAlertOSD, (WPARAM)hContact, (LPARAM) displaytext);
+ NotifyEventHooks(hHookAlertOSD, hContact, (LPARAM) displaytext);
return 0;
}
diff --git a/plugins/WhenWasIt/src/dlg_handlers.cpp b/plugins/WhenWasIt/src/dlg_handlers.cpp index 4a3f6d31bf..589e4c27e0 100644 --- a/plugins/WhenWasIt/src/dlg_handlers.cpp +++ b/plugins/WhenWasIt/src/dlg_handlers.cpp @@ -939,8 +939,8 @@ INT_PTR CALLBACK DlgProcUpcoming(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPar DWORD WINAPI OpenMessageWindowThread(void *data)
{
MCONTACT hContact = (MCONTACT)data;
- CallServiceSync(MS_MSG_SENDMESSAGE, (WPARAM)hContact, 0);
- CallServiceSync("SRMsg/LaunchMessageWindow", (WPARAM)hContact, 0);
+ CallServiceSync(MS_MSG_SENDMESSAGE, hContact, 0);
+ CallServiceSync("SRMsg/LaunchMessageWindow", hContact, 0);
return 0;
}
diff --git a/plugins/WinterSpeak/src/DialogConfigActive.cpp b/plugins/WinterSpeak/src/DialogConfigActive.cpp index 00487967f5..1b63eaae63 100644 --- a/plugins/WinterSpeak/src/DialogConfigActive.cpp +++ b/plugins/WinterSpeak/src/DialogConfigActive.cpp @@ -259,7 +259,7 @@ void DialogConfigActive::SetAllContactIcons(HWND hwndList, HWND window) { if(hContact == 0) {
} else {
- HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, hContact, 0);
if (hItem && SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hItem, MAKELPARAM(1, 0)) == EMPTY_EXTRA_ICON) {
this->InitialiseItem(hwndList, hItem, iter->second.message, iter->second.status);
}
@@ -332,7 +332,7 @@ void DialogConfigActive::save(HWND window) m_db.setActiveFlag(ConfigDatabase::ActiveFlag_Invisible, (IsDlgButtonChecked(window, IDC_ACTIVE_INVISIBLE) != 0));
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
- HANDLE hItem = (HANDLE)SendDlgItemMessage(window, IDC_ACTIVE_USERS, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ HANDLE hItem = (HANDLE)SendDlgItemMessage(window, IDC_ACTIVE_USERS, CLM_FINDCONTACT, hContact, 0);
if (hItem)
SaveItemMask(GetDlgItem(window, IDC_ACTIVE_USERS), hContact, hItem);
}
diff --git a/plugins/XSoundNotify/src/dialog.cpp b/plugins/XSoundNotify/src/dialog.cpp index e83a3df7bd..f77ce80ac3 100644 --- a/plugins/XSoundNotify/src/dialog.cpp +++ b/plugins/XSoundNotify/src/dialog.cpp @@ -40,7 +40,7 @@ static INT_PTR CALLBACK DlgProcContactsOptions(HWND hwndDlg, UINT msg, WPARAM wP break;
}
- TCHAR *nick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *nick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
TCHAR value[100];
mir_sntprintf(value, SIZEOF(value), TranslateT("Custom sound for %s (%s)"), nick, uid);
SetWindowText(hwndDlg, value);
diff --git a/plugins/XSoundNotify/src/options.cpp b/plugins/XSoundNotify/src/options.cpp index 76143744ee..9f6dc980d4 100644 --- a/plugins/XSoundNotify/src/options.cpp +++ b/plugins/XSoundNotify/src/options.cpp @@ -70,7 +70,7 @@ static INT_PTR CALLBACK OptsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l break;
}
- TCHAR *nick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ TCHAR *nick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
TCHAR *value = (TCHAR *)mir_alloc(sizeof(TCHAR) * (_tcslen(uid) + _tcslen(nick) + 4));
mir_sntprintf(value, _tcslen(uid) + _tcslen(nick) + 4, _T("%s (%s)"), nick, uid);
SendMessage(GetDlgItem(hwndDlg, IDC_OPT_COMBO_USERS), CB_SETITEMDATA, SendMessage(GetDlgItem(hwndDlg, IDC_OPT_COMBO_USERS), CB_ADDSTRING, 0, (LPARAM)value), (LPARAM)hContact);
diff --git a/plugins/YAMN/src/browser/mailbrowser.cpp b/plugins/YAMN/src/browser/mailbrowser.cpp index 47f08ecc35..47db479fc0 100644 --- a/plugins/YAMN/src/browser/mailbrowser.cpp +++ b/plugins/YAMN/src/browser/mailbrowser.cpp @@ -891,7 +891,7 @@ LRESULT CALLBACK NewMailPopupProc(HWND hWnd,UINT msg,WPARAM wParam,LPARAM lParam #endif
}
if ((Account->NewMailN.Flags & YAMN_ACC_CONT) && !(Account->NewMailN.Flags & YAMN_ACC_CONTNOEVENT)) {
- CallService(MS_CLIST_REMOVEEVENT,(WPARAM)hContact,(LPARAM)hContact);
+ CallService(MS_CLIST_REMOVEEVENT,hContact,(LPARAM)hContact);
}
}
// fall through
diff --git a/plugins/YAPP/src/options.cpp b/plugins/YAPP/src/options.cpp index 97180ba262..c679060a6b 100644 --- a/plugins/YAPP/src/options.cpp +++ b/plugins/YAPP/src/options.cpp @@ -101,7 +101,7 @@ void ShowExamplePopups() for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
if (options.av_layout != PAV_NONE && ServiceExists(MS_AV_DRAWAVATAR)) {
- AVATARCACHEENTRY *ace = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, (WPARAM)hContact, 0);
+ AVATARCACHEENTRY *ace = (AVATARCACHEENTRY *)CallService(MS_AV_GETAVATARBITMAP, hContact, 0);
if (ace && (ace->dwFlags & AVS_BITMAP_VALID)) {
pd.hContact = hContact;
pd.ptzText = TranslateT("An avatar.");
diff --git a/plugins/YahooGroups/src/utils.cpp b/plugins/YahooGroups/src/utils.cpp index d938abbab3..686cb59363 100644 --- a/plugins/YahooGroups/src/utils.cpp +++ b/plugins/YahooGroups/src/utils.cpp @@ -326,7 +326,7 @@ MCONTACT GetContactFromID(TCHAR *szID, char *szProto) GetContactProtocol(hContact, cProtocol, sizeof(cProtocol));
szHandle = GetContactID(hContact, cProtocol);
- tmp = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
+ tmp = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, hContact, GCDNF_TCHAR);
_tcsncpy(dispName, tmp, SIZEOF(dispName));
if ((szHandle) && ((_tcsicmp(szHandle, szID) == 0) || (_tcsicmp(dispName, szID) == 0)) && ((szProto == NULL) || (_stricmp(szProto, cProtocol) == 0)))
|