summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src/jabber_xstatus.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-11-03 20:16:42 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-11-03 20:16:42 +0000
commitf12d8b56f2894e94491bd7424d69f595d285f01f (patch)
tree3f54d66c8c248bb456da1cb0c5cc31661f144e5f /protocols/JabberG/src/jabber_xstatus.cpp
parent1b1a54dc156bec90be3ddc337c17b4e67179d4ea (diff)
no more MS_CLIST_EXTRA_ADD_ICON in the application code
git-svn-id: http://svn.miranda-ng.org/main/trunk@2175 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/JabberG/src/jabber_xstatus.cpp')
-rw-r--r--protocols/JabberG/src/jabber_xstatus.cpp49
1 files changed, 5 insertions, 44 deletions
diff --git a/protocols/JabberG/src/jabber_xstatus.cpp b/protocols/JabberG/src/jabber_xstatus.cpp
index 5078d7c5c0..c0e278de66 100644
--- a/protocols/JabberG/src/jabber_xstatus.cpp
+++ b/protocols/JabberG/src/jabber_xstatus.cpp
@@ -713,18 +713,7 @@ void CPepMood::ResetExtraIcon(HANDLE hContact)
void CPepMood::SetExtraIcon(HANDLE hContact, char *szMood)
{
- if (hExtraMood != NULL)
- {
- ExtraIcon_SetIcon(hExtraMood, hContact, szMood == NULL ? NULL : m_icons.GetIcolibName(szMood));
- }
- else
- {
- IconExtraColumn iec;
- iec.cbSize = sizeof(iec);
- iec.hImage = m_icons.GetClistHandle(szMood);
- iec.ColumnType = EXTRA_ICON_ADV1;
- CallService(MS_CLIST_EXTRA_SET_ICON, (WPARAM)hContact, (LPARAM)&iec);
- }
+ ExtraIcon_SetIcon(hExtraMood, hContact, szMood == NULL ? NULL : m_icons.GetIcolibName(szMood));
}
void CPepMood::SetMood(HANDLE hContact, const TCHAR *szMood, const TCHAR *szText)
@@ -1145,19 +1134,7 @@ void CPepActivity::ResetExtraIcon(HANDLE hContact)
void CPepActivity::SetExtraIcon(HANDLE hContact, char *szActivity)
{
- if (hExtraActivity != NULL)
- {
- ExtraIcon_SetIcon(hExtraActivity, hContact,
- szActivity == NULL ? NULL : m_icons.GetIcolibName(szActivity));
- }
- else
- {
- IconExtraColumn iec;
- iec.cbSize = sizeof(iec);
- iec.hImage = m_icons.GetClistHandle(szActivity);
- iec.ColumnType = EXTRA_ICON_ADV2;
- CallService(MS_CLIST_EXTRA_SET_ICON, (WPARAM)hContact, (LPARAM)&iec);
- }
+ ExtraIcon_SetIcon(hExtraActivity, hContact, szActivity == NULL ? NULL : m_icons.GetIcolibName(szActivity));
}
void CPepActivity::SetActivity(HANDLE hContact, LPCTSTR szFirst, LPCTSTR szSecond, LPCTSTR szText)
@@ -1245,19 +1222,6 @@ HICON CJabberProto::GetXStatusIcon(int bStatus, UINT flags)
return ( flags & LR_SHARED ) ? icon : CopyIcon( icon );
}
-int CJabberProto::CListMW_ExtraIconsApply( WPARAM wParam, LPARAM )
-{
- if (m_bJabberOnline && m_bPepSupported && ServiceExists(MS_CLIST_EXTRA_SET_ICON))
- {
- char* szProto = ( char* )CallService( MS_PROTO_GETCONTACTBASEPROTO, wParam, 0 );
- if ( szProto==NULL || strcmp( szProto, m_szModuleName ))
- return 0; // only apply icons to our contacts, do not mess others
-
- m_pepServices.ResetExtraIcon((HANDLE)wParam);
- }
- return 0;
-}
-
/////////////////////////////////////////////////////////////////////////////////////////
// JabberGetXStatus - gets the extended status info (mood)
@@ -1465,12 +1429,9 @@ void CJabberProto::InfoFrame_OnUserActivity(CJabberInfoFrame_Event*)
void CJabberProto::XStatusInit()
{
- if (hExtraMood == NULL)
- JHookEvent( ME_CLIST_EXTRA_IMAGE_APPLY, &CJabberProto::CListMW_ExtraIconsApply );
-
- RegisterAdvStatusSlot( ADVSTATUS_MOOD );
- RegisterAdvStatusSlot( ADVSTATUS_TUNE );
- RegisterAdvStatusSlot( ADVSTATUS_ACTIVITY );
+ RegisterAdvStatusSlot(ADVSTATUS_MOOD);
+ RegisterAdvStatusSlot(ADVSTATUS_TUNE);
+ RegisterAdvStatusSlot(ADVSTATUS_ACTIVITY);
}
void CJabberProto::XStatusUninit()