diff options
author | George Hazan <george.hazan@gmail.com> | 2014-02-10 21:37:41 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-02-10 21:37:41 +0000 |
commit | ee68ac82d5aabb596e8bd0f2b9286827ca2ce545 (patch) | |
tree | 2b330d60da88d6c195ae1943ad93fe2b393469fd /plugins/Clist_modern | |
parent | 6aff7a968c46f4080a24bd372c6ec1337766adf7 (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/Clist_modern')
-rw-r--r-- | plugins/Clist_modern/src/modern_clc.cpp | 50 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_clcmsgs.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_clistmenus.cpp | 4 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_clistsettings.cpp | 6 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_clui.cpp | 4 |
5 files changed, 33 insertions, 33 deletions
diff --git a/plugins/Clist_modern/src/modern_clc.cpp b/plugins/Clist_modern/src/modern_clc.cpp index 2cbe60d814..ac75da25a4 100644 --- a/plugins/Clist_modern/src/modern_clc.cpp +++ b/plugins/Clist_modern/src/modern_clc.cpp @@ -162,7 +162,7 @@ static int clcHookSmileyAddOptionsChanged(WPARAM wParam,LPARAM lParam) static int clcHookProtoAck(WPARAM wParam, LPARAM lParam)
{
- return ClcDoProtoAck((MCONTACT)wParam, (ACKDATA*)lParam);
+ return ClcDoProtoAck(wParam, (ACKDATA*)lParam);
}
static int clcHookIconsChanged(WPARAM wParam, LPARAM lParam)
@@ -259,7 +259,7 @@ static int clcHookSettingChanged(WPARAM wParam,LPARAM lParam) else if (!strcmp(cws->szSetting,"ListeningTo"))
pcli->pfnClcBroadcast( INTM_STATUSMSGCHANGED,wParam,0);
else if (!strcmp(cws->szSetting,"Transport") || !strcmp(cws->szSetting,"IsTransported")) {
- pcli->pfnInvalidateDisplayNameCacheEntry((MCONTACT)wParam);
+ pcli->pfnInvalidateDisplayNameCacheEntry(wParam);
pcli->pfnClcBroadcast( CLM_AUTOREBUILD,wParam,0);
}
}
@@ -274,8 +274,8 @@ static int clcHookDbEventAdded(WPARAM wParam,LPARAM lParam) DBEVENTINFO dbei = { sizeof(dbei) };
db_event_get((HANDLE)lParam, &dbei);
if (dbei.eventType == EVENTTYPE_MESSAGE && !(dbei.flags & DBEF_SENT)) {
- ClcCacheEntry *pdnce = pcli->pfnGetCacheEntry((MCONTACT)wParam);
- db_set_dw((MCONTACT)wParam, "CList", "mf_lastmsg", dbei.timestamp);
+ ClcCacheEntry *pdnce = pcli->pfnGetCacheEntry(wParam);
+ db_set_dw(wParam, "CList", "mf_lastmsg", dbei.timestamp);
if (pdnce)
pdnce->dwLastMsgTime = dbei.timestamp;
}
@@ -1476,10 +1476,10 @@ static LRESULT clcOnIntmGroupChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM w memcpy(iExtraImage, contact->iExtraImage, sizeof(iExtraImage));
flags = contact->flags;
}
- pcli->pfnDeleteItemFromTree(hwnd, (MCONTACT)wParam);
- if (GetWindowLongPtr(hwnd, GWL_STYLE) & CLS_SHOWHIDDEN || !db_get_b((MCONTACT)wParam, "CList", "Hidden", 0)) {
+ pcli->pfnDeleteItemFromTree(hwnd, wParam);
+ if (GetWindowLongPtr(hwnd, GWL_STYLE) & CLS_SHOWHIDDEN || !db_get_b(wParam, "CList", "Hidden", 0)) {
NMCLISTCONTROL nm;
- pcli->pfnAddContactToTree(hwnd, dat, (MCONTACT)wParam, 1, 1);
+ pcli->pfnAddContactToTree(hwnd, dat, wParam, 1, 1);
if (pcli->pfnFindItem(hwnd, dat, (HANDLE)wParam, &contact, NULL, NULL)) {
memcpy(contact->iExtraImage, iExtraImage, sizeof(iExtraImage));
if (flags & CONTACTF_CHECKED)
@@ -1505,24 +1505,24 @@ static LRESULT clcOnIntmIconChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wP BOOL needRepaint = FALSE;
WORD status;
RECT iconRect = {0};
- int contacticon = corecli.pfnGetContactIcon((MCONTACT)wParam);
+ int contacticon = corecli.pfnGetContactIcon(wParam);
MCONTACT hSelItem = NULL;
ClcContact *selcontact = NULL;
- char *szProto = GetContactProto((MCONTACT)wParam);
+ char *szProto = GetContactProto(wParam);
if (szProto == NULL)
status = ID_STATUS_OFFLINE;
else
- status = GetContactCachedStatus((MCONTACT)wParam);
+ status = GetContactCachedStatus(wParam);
BOOL image_is_special = (LOWORD(contacticon) != (LOWORD(lParam))); //check only base icons
- int nHiddenStatus = CLVM_GetContactHiddenStatus((MCONTACT)wParam, szProto, dat);
+ int nHiddenStatus = CLVM_GetContactHiddenStatus(wParam, szProto, dat);
DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
bool isVisiblebyFilter = (( ( style & CLS_SHOWHIDDEN ) && nHiddenStatus != -1 ) || !nHiddenStatus );
bool ifVisibleByClui = !pcli->pfnIsHiddenMode( dat, status );
bool isVisible = g_CluiData.bFilterEffective&CLVM_FILTER_STATUS ? TRUE : ifVisibleByClui;
- bool isIconChanged = cli_GetContactIcon((MCONTACT)wParam) != LOWORD(lParam);
+ bool isIconChanged = cli_GetContactIcon(wParam) != LOWORD(lParam);
shouldShow = isVisiblebyFilter && ( isVisible || isIconChanged ) ;
@@ -1532,14 +1532,14 @@ static LRESULT clcOnIntmIconChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wP if (shouldShow && CallService(MS_DB_CONTACT_IS, wParam, 0)) {
if (dat->selection >= 0 && pcli->pfnGetRowByIndex(dat, dat->selection, &selcontact, NULL) != -1)
hSelItem = (MCONTACT)pcli->pfnContactToHItem(selcontact);
- pcli->pfnAddContactToTree(hwnd, dat, (MCONTACT)wParam, (style & CLS_CONTACTLIST) == 0, 0);
+ pcli->pfnAddContactToTree(hwnd, dat, wParam, (style & CLS_CONTACTLIST) == 0, 0);
recalcScrollBar = 1;
needRepaint = TRUE;
pcli->pfnFindItem(hwnd, dat, (HANDLE)wParam, &contact, NULL, NULL);
if (contact) {
contact->iImage = lParam;
contact->image_is_special = image_is_special;
- pcli->pfnNotifyNewContact(hwnd, (MCONTACT)wParam);
+ pcli->pfnNotifyNewContact(hwnd, wParam);
dat->needsResort = 1;
}
}
@@ -1601,7 +1601,7 @@ static LRESULT clcOnIntmIconChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wP static LRESULT clcOnIntmAvatarChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
ClcContact *contact;
- if (FindItem(hwnd, dat, (MCONTACT)wParam, &contact, NULL, NULL, FALSE))
+ if (FindItem(hwnd, dat, wParam, &contact, NULL, NULL, FALSE))
Cache_GetAvatar(dat, contact);
else if (dat->use_avatar_service && !wParam)
UpdateAllAvatars(dat);
@@ -1613,7 +1613,7 @@ static LRESULT clcOnIntmAvatarChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM static LRESULT clcOnIntmTimeZoneChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
ClcContact *contact;
- if (!FindItem(hwnd, dat, (MCONTACT)wParam, &contact, NULL, NULL, FALSE))
+ if (!FindItem(hwnd, dat, wParam, &contact, NULL, NULL, FALSE))
return corecli.pfnContactListControlWndProc(hwnd,msg,wParam,lParam);
if (contact) {
@@ -1628,13 +1628,13 @@ static LRESULT clcOnIntmNameChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wP {
int ret = corecli.pfnContactListControlWndProc(hwnd, msg, wParam, lParam);
- pcli->pfnInvalidateDisplayNameCacheEntry((MCONTACT)wParam);
+ pcli->pfnInvalidateDisplayNameCacheEntry(wParam);
ClcContact *contact;
- if (!FindItem(hwnd, dat, (MCONTACT)wParam, &contact, NULL, NULL, FALSE))
+ if (!FindItem(hwnd, dat, wParam, &contact, NULL, NULL, FALSE))
return ret;
- lstrcpyn(contact->szText, pcli->pfnGetContactDisplayName((MCONTACT)wParam, 0), SIZEOF(contact->szText));
+ lstrcpyn(contact->szText, pcli->pfnGetContactDisplayName(wParam, 0), SIZEOF(contact->szText));
if (contact) {
Cache_GetText(dat,contact,1);
cliRecalcScrollBar(hwnd,dat);
@@ -1653,7 +1653,7 @@ static LRESULT clcOnIntmApparentModeChanged(ClcData *dat, HWND hwnd, UINT msg, W static LRESULT clcOnIntmStatusMsgChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
ClcContact *contact;
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
if (hContact == NULL || IsHContactInfo(hContact) || IsHContactGroup(hContact))
return corecli.pfnContactListControlWndProc(hwnd, msg, wParam, lParam);
if (!FindItem(hwnd,dat,hContact,&contact,NULL,NULL,FALSE))
@@ -1672,7 +1672,7 @@ static LRESULT clcOnIntmNotOnListChanged(ClcData *dat, HWND hwnd, UINT msg, WPAR DBCONTACTWRITESETTING *dbcws = (DBCONTACTWRITESETTING*)lParam;
ClcContact *contact;
- if (!FindItem(hwnd, dat, (MCONTACT)wParam, &contact, NULL, NULL, TRUE))
+ if (!FindItem(hwnd, dat, wParam, &contact, NULL, NULL, TRUE))
return corecli.pfnContactListControlWndProc(hwnd, msg, wParam, lParam);
if (contact->type != CLCIT_CONTACT)
@@ -1702,18 +1702,18 @@ static LRESULT clcOnIntmStatusChanged(ClcData *dat, HWND hwnd, UINT msg, WPARAM {
int ret = corecli.pfnContactListControlWndProc(hwnd, msg, wParam, lParam);
if (wParam != 0) {
- ClcCacheEntry *pdnce = pcli->pfnGetCacheEntry((MCONTACT)wParam);
+ ClcCacheEntry *pdnce = pcli->pfnGetCacheEntry(wParam);
if (pdnce && pdnce->m_cache_cszProto) {
pdnce___SetStatus( pdnce, GetStatusForContact(pdnce->hContact,pdnce->m_cache_cszProto));
if (!dat->force_in_dialog && (dat->second_line_show || dat->third_line_show))
gtaRenewText(pdnce->hContact);
- SendMessage(hwnd, INTM_ICONCHANGED, wParam, corecli.pfnGetContactIcon((MCONTACT)wParam));
+ SendMessage(hwnd, INTM_ICONCHANGED, wParam, corecli.pfnGetContactIcon(wParam));
ClcContact *contact;
- if (FindItem(hwnd, dat, (MCONTACT)wParam, &contact, NULL, NULL, TRUE)) {
+ if (FindItem(hwnd, dat, wParam, &contact, NULL, NULL, TRUE)) {
if (contact && contact->type == CLCIT_CONTACT) {
if (!contact->image_is_special && pdnce___GetStatus( pdnce ) > ID_STATUS_OFFLINE)
- contact->iImage = corecli.pfnGetContactIcon((MCONTACT)wParam);
+ contact->iImage = corecli.pfnGetContactIcon(wParam);
if (contact->isSubcontact && contact->subcontacts && contact->subcontacts->type == CLCIT_CONTACT)
pcli->pfnClcBroadcast(INTM_STATUSCHANGED, (WPARAM)contact->subcontacts->hContact, 0); //forward status changing to host meta contact
}
diff --git a/plugins/Clist_modern/src/modern_clcmsgs.cpp b/plugins/Clist_modern/src/modern_clcmsgs.cpp index f0933fc4bc..d048f249a5 100644 --- a/plugins/Clist_modern/src/modern_clcmsgs.cpp +++ b/plugins/Clist_modern/src/modern_clcmsgs.cpp @@ -35,7 +35,7 @@ LRESULT cli_ProcessExternalMessages(HWND hwnd,ClcData *dat,UINT msg,WPARAM wPara switch(msg) {
case CLM_DELETEITEM:
- pcli->pfnDeleteItemFromTree(hwnd, (MCONTACT)wParam);
+ pcli->pfnDeleteItemFromTree(hwnd, wParam);
clcSetDelayTimer( TIMERID_DELAYEDRESORTCLC, hwnd, 1 ); //pcli->pfnSortCLC(hwnd, dat, 1);
clcSetDelayTimer( TIMERID_RECALCSCROLLBAR, hwnd, 2 ); //pcli->pfnRecalcScrollBar(hwnd, dat);
return 0;
diff --git a/plugins/Clist_modern/src/modern_clistmenus.cpp b/plugins/Clist_modern/src/modern_clistmenus.cpp index 28db20bfde..c93d4982cb 100644 --- a/plugins/Clist_modern/src/modern_clistmenus.cpp +++ b/plugins/Clist_modern/src/modern_clistmenus.cpp @@ -94,7 +94,7 @@ static IconItem iconList[] = static int FAV_OnContactMenuBuild(WPARAM wParam,LPARAM lParam)
{
- BYTE bContactRate = db_get_b((MCONTACT)wParam, "CList", "Rate", 0);
+ BYTE bContactRate = db_get_b(wParam, "CList", "Rate", 0);
if ( bContactRate > SIZEOF(rates)-1)
bContactRate = SIZEOF(rates)-1;
@@ -149,7 +149,7 @@ static int FAV_OnContactMenuBuild(WPARAM wParam,LPARAM lParam) mi.hIcon = NULL;
mi.ptszName = LPGENT("Show even if offline");
- mi.flags = CMIF_CHILDPOPUP | CMIF_TCHAR | (db_get_b((MCONTACT)wParam, "CList", "noOffline", 0) ? CMIF_CHECKED : 0);
+ mi.flags = CMIF_CHILDPOPUP | CMIF_TCHAR | (db_get_b(wParam, "CList", "noOffline", 0) ? CMIF_CHECKED : 0);
mi.pszService = CLUI_FAVTOGGLESHOWOFFLINE;
mi.popupPosition = i+100000000;
mi.position = -100000000;
diff --git a/plugins/Clist_modern/src/modern_clistsettings.cpp b/plugins/Clist_modern/src/modern_clistsettings.cpp index f59c355d4a..97b18e1b7b 100644 --- a/plugins/Clist_modern/src/modern_clistsettings.cpp +++ b/plugins/Clist_modern/src/modern_clistsettings.cpp @@ -417,7 +417,7 @@ int GetContactCachedStatus(MCONTACT hContact) int ContactAdded(WPARAM wParam,LPARAM lParam)
{
if (!MirandaExiting()) {
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
cli_ChangeContactIcon(hContact,pcli->pfnIconFromStatusMode((char*)GetContactCachedProtocol(hContact),ID_STATUS_OFFLINE,hContact),1); ///by FYR
pcli->pfnSortContacts();
}
@@ -426,7 +426,7 @@ int ContactAdded(WPARAM wParam,LPARAM lParam) int ContactSettingChanged(WPARAM wParam,LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
if (MirandaExiting() || !pcli || !clistCache || hContact == NULL)
return 0;
@@ -494,7 +494,7 @@ int ContactSettingChanged(WPARAM wParam,LPARAM lParam) else if (!strcmp(cws->szSetting,"Hidden")) {
InvalidateDNCEbyPointer(hContact,pdnce,cws->value.type);
if (cws->value.type == DBVT_DELETED || cws->value.bVal == 0) {
- char *szProto = GetContactProto((MCONTACT)wParam);
+ char *szProto = GetContactProto(wParam);
cli_ChangeContactIcon(hContact,pcli->pfnIconFromStatusMode(szProto,
szProto == NULL ? ID_STATUS_OFFLINE : db_get_w(hContact,szProto,"Status",ID_STATUS_OFFLINE), hContact),1); //by FYR
}
diff --git a/plugins/Clist_modern/src/modern_clui.cpp b/plugins/Clist_modern/src/modern_clui.cpp index 86db9f4b91..0887cff8b8 100644 --- a/plugins/Clist_modern/src/modern_clui.cpp +++ b/plugins/Clist_modern/src/modern_clui.cpp @@ -240,7 +240,7 @@ INT_PTR CLUI::Service_ShowStatusMenu(WPARAM wParam,LPARAM lParam) INT_PTR CLUI::Service_Menu_ShowContactAvatar(WPARAM wParam,LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
db_set_b(hContact, "CList", "HideContactAvatar", 0);
@@ -250,7 +250,7 @@ INT_PTR CLUI::Service_Menu_ShowContactAvatar(WPARAM wParam,LPARAM lParam) INT_PTR CLUI::Service_Menu_HideContactAvatar(WPARAM wParam,LPARAM lParam)
{
- MCONTACT hContact = (MCONTACT)wParam;
+ MCONTACT hContact = wParam;
db_set_b(hContact, "CList", "HideContactAvatar", 1);
|