summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-02-10 21:37:41 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-02-10 21:37:41 +0000
commitee68ac82d5aabb596e8bd0f2b9286827ca2ce545 (patch)
tree2b330d60da88d6c195ae1943ad93fe2b393469fd /plugins/TabSRMM
parent6aff7a968c46f4080a24bd372c6ec1337766adf7 (diff)
these conversions aren't needed either
git-svn-id: http://svn.miranda-ng.org/main/trunk@8088 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TabSRMM')
-rw-r--r--plugins/TabSRMM/src/buttonsbar.cpp4
-rw-r--r--plugins/TabSRMM/src/container.cpp6
-rw-r--r--plugins/TabSRMM/src/generic_msghandlers.cpp4
-rw-r--r--plugins/TabSRMM/src/globals.cpp10
-rw-r--r--plugins/TabSRMM/src/hotkeyhandler.cpp12
-rw-r--r--plugins/TabSRMM/src/mim.cpp10
-rw-r--r--plugins/TabSRMM/src/msgdialog.cpp2
-rw-r--r--plugins/TabSRMM/src/msgs.cpp18
-rw-r--r--plugins/TabSRMM/src/sendlater.cpp2
-rw-r--r--plugins/TabSRMM/src/typingnotify.cpp2
-rw-r--r--plugins/TabSRMM/src/userprefs.cpp6
11 files changed, 38 insertions, 38 deletions
diff --git a/plugins/TabSRMM/src/buttonsbar.cpp b/plugins/TabSRMM/src/buttonsbar.cpp
index e3f277319e..0215f7dc1d 100644
--- a/plugins/TabSRMM/src/buttonsbar.cpp
+++ b/plugins/TabSRMM/src/buttonsbar.cpp
@@ -350,7 +350,7 @@ static INT_PTR CB_GetButtonState(WPARAM wParam, LPARAM lParam)
if (!realbutton)
return 1;
- HWND hwndDlg = M.FindWindow((MCONTACT)wParam);
+ HWND hwndDlg = M.FindWindow(wParam);
if(!hwndDlg)
return 1;
HWND hwndBtn = GetDlgItem(hwndDlg, tempCID);
@@ -385,7 +385,7 @@ static INT_PTR CB_SetButtonState(WPARAM wParam, LPARAM lParam)
if (!realbutton)
return 1;
- HWND hwndDlg = M.FindWindow((MCONTACT)wParam);
+ HWND hwndDlg = M.FindWindow(wParam);
if(!hwndDlg)
return 1;
diff --git a/plugins/TabSRMM/src/container.cpp b/plugins/TabSRMM/src/container.cpp
index f51d760d92..b4dbc18193 100644
--- a/plugins/TabSRMM/src/container.cpp
+++ b/plugins/TabSRMM/src/container.cpp
@@ -1197,15 +1197,15 @@ panel_found:
dat = (TWindowData*)GetWindowLongPtr(pContainer->hwndActive, GWLP_USERDATA);
}
else {
- HWND hwnd = M.FindWindow((MCONTACT)wParam);
+ HWND hwnd = M.FindWindow(wParam);
if (hwnd == 0) {
- SESSION_INFO *si = SM_FindSessionByHCONTACT((MCONTACT)wParam);
+ SESSION_INFO *si = SM_FindSessionByHCONTACT(wParam);
if (si) {
SendMessage(si->hWnd, GC_UPDATETITLE, 0, 0);
return 0;
}
}
- hContact = (MCONTACT)wParam;
+ hContact = wParam;
if (hwnd && hContact)
dat = (TWindowData*)GetWindowLongPtr(hwnd, GWLP_USERDATA);
}
diff --git a/plugins/TabSRMM/src/generic_msghandlers.cpp b/plugins/TabSRMM/src/generic_msghandlers.cpp
index cebd17df30..d607e38931 100644
--- a/plugins/TabSRMM/src/generic_msghandlers.cpp
+++ b/plugins/TabSRMM/src/generic_msghandlers.cpp
@@ -1626,7 +1626,7 @@ void TSAPI DM_EventAdded(TWindowData *dat, WPARAM wParam, LPARAM lParam)
SendMessage(hwndDlg, DM_ADDDIVIDER, 0, 0);
}
}
- tabSRMM_ShowPopup((MCONTACT)wParam, hDbEvent, dbei.eventType, m_pContainer->fHidden ? 0 : 1, m_pContainer, hwndDlg, dat->cache->getActiveProto(), dat);
+ tabSRMM_ShowPopup(wParam, hDbEvent, dbei.eventType, m_pContainer->fHidden ? 0 : 1, m_pContainer, hwndDlg, dat->cache->getActiveProto(), dat);
if (IsWindowVisible(m_pContainer->hwnd))
m_pContainer->fHidden = false;
}
@@ -1895,7 +1895,7 @@ static HANDLE hHookIconPressedEvt;
static int OnSrmmIconChanged(WPARAM wParam, LPARAM)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
if (hContact == NULL)
M.BroadcastMessage(DM_STATUSICONCHANGE, 0, 0);
else {
diff --git a/plugins/TabSRMM/src/globals.cpp b/plugins/TabSRMM/src/globals.cpp
index 15e32170e8..1422425ce2 100644
--- a/plugins/TabSRMM/src/globals.cpp
+++ b/plugins/TabSRMM/src/globals.cpp
@@ -402,11 +402,11 @@ int CGlobals::DBSettingChanged(WPARAM wParam, LPARAM lParam)
CContactCache* c = 0;
bool fChanged = false, fNickChanged = false, fExtendedStatusChange = false;
- hwnd = M.FindWindow((MCONTACT)wParam);
+ hwnd = M.FindWindow(wParam);
if (hwnd == 0 && wParam != 0) { // we are not interested in this event if there is no open message window/tab
if (!strcmp(setting, "Status") || !strcmp(setting, "MyHandle") || !strcmp(setting, "Nick") || !strcmp(cws->szModule, SRMSGMOD_T)) {
- c = CContactCache::getContactCache((MCONTACT)wParam);
+ c = CContactCache::getContactCache(wParam);
if (c) {
fChanged = c->updateStatus();
if (strcmp(setting, "Status"))
@@ -424,7 +424,7 @@ int CGlobals::DBSettingChanged(WPARAM wParam, LPARAM lParam)
}
if (wParam) {
- c = CContactCache::getContactCache((MCONTACT)wParam);
+ c = CContactCache::getContactCache(wParam);
if (c) {
szProto = c->getProto();
if (!strcmp(cws->szModule, SRMSGMOD_T)) { // catch own relevant settings
@@ -500,7 +500,7 @@ int CGlobals::DBSettingChanged(WPARAM wParam, LPARAM lParam)
int CGlobals::DBContactDeleted(WPARAM wParam, LPARAM lParam)
{
if (wParam) {
- CContactCache *c = CContactCache::getContactCache((MCONTACT)wParam);
+ CContactCache *c = CContactCache::getContactCache(wParam);
if (c)
c->deletedHandler();
}
@@ -515,7 +515,7 @@ int CGlobals::DBContactDeleted(WPARAM wParam, LPARAM lParam)
int CGlobals::MetaContactEvent(WPARAM wParam, LPARAM lParam)
{
if (wParam) {
- CContactCache *c = CContactCache::getContactCache((MCONTACT)wParam);
+ CContactCache *c = CContactCache::getContactCache(wParam);
if (c) {
c->updateMeta(true);
if (c->getHwnd()) {
diff --git a/plugins/TabSRMM/src/hotkeyhandler.cpp b/plugins/TabSRMM/src/hotkeyhandler.cpp
index ff4a710b64..8b9b05d388 100644
--- a/plugins/TabSRMM/src/hotkeyhandler.cpp
+++ b/plugins/TabSRMM/src/hotkeyhandler.cpp
@@ -372,7 +372,7 @@ LONG_PTR CALLBACK HotkeyHandlerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LP
* if lParam == NULL, don't consider clist events, just open the message tab
*/
if (lParam == 0)
- HandleMenuEntryFromhContact((MCONTACT)wParam);
+ HandleMenuEntryFromhContact(wParam);
else {
CLISTEVENT *cle = (CLISTEVENT *)CallService(MS_CLIST_GETEVENT, wParam, 0);
if (cle) {
@@ -382,13 +382,13 @@ LONG_PTR CALLBACK HotkeyHandlerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LP
}
}
// still, we got that message posted.. the event may be waiting in tabSRMMs tray...
- else HandleMenuEntryFromhContact((MCONTACT)wParam);
+ else HandleMenuEntryFromhContact(wParam);
}
break;
case DM_DOCREATETAB:
{
- HWND hWnd = M.FindWindow((MCONTACT)lParam);
+ HWND hWnd = M.FindWindow(lParam);
if (hWnd && IsWindow(hWnd)) {
TContainerData *pContainer = 0;
SendMessage(hWnd, DM_QUERYCONTAINER, 0, (LPARAM)&pContainer);
@@ -399,7 +399,7 @@ LONG_PTR CALLBACK HotkeyHandlerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LP
else
SendMessage(hWnd, WM_CLOSE, 0, 1);
- CreateNewTabForContact((TContainerData*)wParam, (MCONTACT)lParam, 0, NULL, TRUE, TRUE, FALSE, 0);
+ CreateNewTabForContact((TContainerData*)wParam, lParam, 0, NULL, TRUE, TRUE, FALSE, 0);
}
}
}
@@ -441,13 +441,13 @@ LONG_PTR CALLBACK HotkeyHandlerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LP
*/
case DM_REMOVECLISTEVENT:
CallService(MS_CLIST_REMOVEEVENT, wParam, lParam);
- db_event_markRead((MCONTACT)wParam, (HANDLE)lParam);
+ db_event_markRead(wParam, (HANDLE)lParam);
return 0;
case DM_SETLOCALE:
{
HKL hkl = (HKL)lParam;
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
HWND hWnd = M.FindWindow(hContact);
if (hWnd) {
diff --git a/plugins/TabSRMM/src/mim.cpp b/plugins/TabSRMM/src/mim.cpp
index 7c81027490..8b069edb8b 100644
--- a/plugins/TabSRMM/src/mim.cpp
+++ b/plugins/TabSRMM/src/mim.cpp
@@ -335,7 +335,7 @@ int CMimAPI::TypingMessage(WPARAM wParam, LPARAM lParam)
int issplit = 1, foundWin = 0, preTyping = 0;
BOOL fShowOnClist = TRUE;
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
if (hContact) {
if ((hwnd = M.FindWindow(hContact)) && M.GetByte(SRMSGMOD, SRMSGSET_SHOWTYPING, SRMSGDEFSET_SHOWTYPING))
preTyping = SendMessage(hwnd, DM_TYPING, 0, lParam);
@@ -407,7 +407,7 @@ int CMimAPI::TypingMessage(WPARAM wParam, LPARAM lParam)
}
if (fShowOnClist) {
CLISTEVENT cle = { sizeof(cle) };
- cle.hContact = (MCONTACT)wParam;
+ cle.hContact = wParam;
cle.hDbEvent = (HANDLE)1;
cle.flags = CLEF_ONLYAFEW | CLEF_TCHAR;
cle.hIcon = PluginConfig.g_buttonBarIcons[ICON_DEFAULT_TYPING];
@@ -468,7 +468,7 @@ int CMimAPI::ProtoAck(WPARAM wParam, LPARAM lParam)
int CMimAPI::PrebuildContactMenu(WPARAM wParam, LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
if (hContact == NULL)
return NULL;
@@ -497,7 +497,7 @@ int CMimAPI::PrebuildContactMenu(WPARAM wParam, LPARAM lParam)
int CMimAPI::DispatchNewEvent(WPARAM wParam, LPARAM lParam)
{
if (wParam) {
- HWND h = M.FindWindow((MCONTACT)wParam);
+ HWND h = M.FindWindow(wParam);
if (h)
PostMessage(h, HM_DBEVENTADDED, wParam, lParam); // was SENDMESSAGE !!! XXX
}
@@ -522,7 +522,7 @@ int CMimAPI::MessageEventAdded(WPARAM wParam, LPARAM lParam)
DBEVENTINFO dbei = { sizeof(dbei) };
db_event_get(hDbEvent, &dbei);
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
HWND hwnd = M.FindWindow(hContact);
BOOL isCustomEvent = IsCustomEvent(dbei.eventType);
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp
index 4789769410..9ab3fa73ff 100644
--- a/plugins/TabSRMM/src/msgdialog.cpp
+++ b/plugins/TabSRMM/src/msgdialog.cpp
@@ -2547,7 +2547,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP
case HM_DBEVENTADDED:
if (!dat)
return 0;
- if ((MCONTACT)wParam != dat->hContact)
+ if (wParam != dat->hContact)
return 0;
if (dat->hContact == NULL)
return 0;
diff --git a/plugins/TabSRMM/src/msgs.cpp b/plugins/TabSRMM/src/msgs.cpp
index e6b2fe0ea7..a64a8661b4 100644
--- a/plugins/TabSRMM/src/msgs.cpp
+++ b/plugins/TabSRMM/src/msgs.cpp
@@ -133,7 +133,7 @@ static INT_PTR SetStatusText(WPARAM wParam, LPARAM lParam)
{
TContainerData *pContainer;
- HWND hwnd = M.FindWindow((MCONTACT)wParam);
+ HWND hwnd = M.FindWindow(wParam);
if (hwnd != NULL) {
TWindowData *dat = (TWindowData*)GetWindowLongPtr(hwnd, GWLP_USERDATA);
if (dat == NULL || (pContainer = dat->pContainer) == NULL)
@@ -150,7 +150,7 @@ static INT_PTR SetStatusText(WPARAM wParam, LPARAM lParam)
return 1;
}
else {
- SESSION_INFO *si = SM_FindSessionByHCONTACT((MCONTACT)wParam);
+ SESSION_INFO *si = SM_FindSessionByHCONTACT(wParam);
if (si == NULL || si->hWnd == 0 || (pContainer = si->pContainer) == NULL || pContainer->hwndActive != si->hWnd)
return 1;
}
@@ -166,7 +166,7 @@ static INT_PTR SetStatusText(WPARAM wParam, LPARAM lParam)
static INT_PTR SetUserPrefs(WPARAM wParam, LPARAM)
{
- HWND hWnd = WindowList_Find(PluginConfig.hUserPrefsWindowList, (MCONTACT)wParam);
+ HWND hWnd = WindowList_Find(PluginConfig.hUserPrefsWindowList, wParam);
if (hWnd) {
SetForegroundWindow(hWnd); // already open, bring it to front
return 0;
@@ -197,7 +197,7 @@ static INT_PTR GetMessageWindowFlags(WPARAM wParam, LPARAM lParam)
HWND hwndTarget = (HWND)lParam;
if (hwndTarget == 0)
- hwndTarget = M.FindWindow((MCONTACT)wParam);
+ hwndTarget = M.FindWindow(wParam);
if (hwndTarget == 0)
return 0;
@@ -234,7 +234,7 @@ INT_PTR MessageWindowOpened(WPARAM wParam, LPARAM lParam)
TContainerData *pContainer = NULL;
if (wParam)
- hwnd = M.FindWindow((MCONTACT)wParam);
+ hwnd = M.FindWindow(wParam);
else if (lParam)
hwnd = (HWND) lParam;
else
@@ -296,7 +296,7 @@ static INT_PTR ReadMessageCommand(WPARAM, LPARAM lParam)
INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
TNewWindowData newData = { 0 };
int isSplit = 1;
@@ -355,7 +355,7 @@ INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam)
INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
TNewWindowData newData = { 0 };
int isSplit = 1;
@@ -391,7 +391,7 @@ INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam)
SendMessage(hwnd, DM_ACTIVATEME, 0, 0); // ask the message window about its parent...
} else {
TCHAR szName[CONTAINER_NAMELEN + 1];
- GetContainerNameForContact((MCONTACT)wParam, szName, CONTAINER_NAMELEN);
+ GetContainerNameForContact(wParam, szName, CONTAINER_NAMELEN);
TContainerData *pContainer = FindContainerByName(szName);
if (pContainer == NULL)
pContainer = CreateContainer(szName, FALSE, hContact);
@@ -465,7 +465,7 @@ int MyAvatarChanged(WPARAM wParam, LPARAM lParam)
int AvatarChanged(WPARAM wParam, LPARAM lParam)
{
avatarCacheEntry *ace = (avatarCacheEntry *)lParam;
- HWND hwnd = M.FindWindow((MCONTACT)wParam);
+ HWND hwnd = M.FindWindow(wParam);
if (wParam == 0) { // protocol picture has changed...
M.BroadcastMessage(DM_PROTOAVATARCHANGED, wParam, lParam);
diff --git a/plugins/TabSRMM/src/sendlater.cpp b/plugins/TabSRMM/src/sendlater.cpp
index 38ab2fc16f..f93c65ce53 100644
--- a/plugins/TabSRMM/src/sendlater.cpp
+++ b/plugins/TabSRMM/src/sendlater.cpp
@@ -310,7 +310,7 @@ void CSendLater::processContacts()
*/
int CSendLater::addJob(const char *szSetting, LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)lParam;
+ MCONTACT hContact = lParam;
DBVARIANT dbv = {0};
char *szOrig_Utf = 0;
diff --git a/plugins/TabSRMM/src/typingnotify.cpp b/plugins/TabSRMM/src/typingnotify.cpp
index 33b12efd28..6652ece4ad 100644
--- a/plugins/TabSRMM/src/typingnotify.cpp
+++ b/plugins/TabSRMM/src/typingnotify.cpp
@@ -363,7 +363,7 @@ static INT_PTR CALLBACK DlgProcOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA
}
ppd.lchIcon = PluginConfig.g_buttonBarIcons[ICON_DEFAULT_TYPING];
- ppd.lchContact = (MCONTACT)wParam;
+ ppd.lchContact = wParam;
ppd.PluginWindowProc = NULL;
ppd.PluginData = NULL;
PUAddPopupT(&ppd);
diff --git a/plugins/TabSRMM/src/userprefs.cpp b/plugins/TabSRMM/src/userprefs.cpp
index 5c3389748d..0d9bc82499 100644
--- a/plugins/TabSRMM/src/userprefs.cpp
+++ b/plugins/TabSRMM/src/userprefs.cpp
@@ -63,7 +63,7 @@ static INT_PTR CALLBACK DlgProcUserPrefs(HWND hwndDlg, UINT msg, WPARAM wParam,
case WM_INITDIALOG: {
DWORD sCodePage;
int i;
- hContact = (MCONTACT)lParam;
+ hContact = lParam;
DWORD maxhist = M.GetDword(hContact, "maxhist", 0);
BYTE bIEView = M.GetByte(hContact, "ieview", 0);
BYTE bHPP = M.GetByte(hContact, "hpplog", 0);
@@ -365,7 +365,7 @@ static INT_PTR CALLBACK DlgProcUserPrefsLogOptions(HWND hwndDlg, UINT msg, WPARA
MCONTACT hContact = (MCONTACT)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
switch (msg) {
case WM_INITDIALOG:
- hContact = (MCONTACT)lParam;
+ hContact = lParam;
TranslateDialogDefault(hwndDlg);
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, (LONG_PTR)hContact);
SendMessage(hwndDlg, WM_COMMAND, WM_USER + 200, 0);
@@ -464,7 +464,7 @@ INT_PTR CALLBACK DlgProcUserPrefsFrame(HWND hwndDlg, UINT msg, WPARAM wParam, LP
case WM_INITDIALOG:
TranslateDialogDefault(hwndDlg);
- hContact = (MCONTACT)lParam;
+ hContact = lParam;
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, (LONG_PTR)hContact);
WindowList_Add(PluginConfig.hUserPrefsWindowList, hwndDlg, hContact);