summaryrefslogtreecommitdiff
path: root/protocols
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-04-12 14:19:40 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-04-12 14:19:40 +0000
commit23e6fe719ec331e47548e72c00883b8192b8c3fb (patch)
tree22de4daf47f9bb00b16eb3409d67fc3cc919392c /protocols
parent3e1583072445a97fbd9dd223d8c8b702013ae1d6 (diff)
unneeded object creation removed
git-svn-id: http://svn.miranda-ng.org/main/trunk@12774 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols')
-rw-r--r--protocols/JabberG/src/jabber_frame.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/protocols/JabberG/src/jabber_frame.cpp b/protocols/JabberG/src/jabber_frame.cpp
index 55e4f939d1..224bae3337 100644
--- a/protocols/JabberG/src/jabber_frame.cpp
+++ b/protocols/JabberG/src/jabber_frame.cpp
@@ -443,8 +443,7 @@ void CJabberInfoFrame::PaintNormal(HDC hdc)
void CJabberInfoFrame::CreateInfoItem(char *pszName, bool bCompact, LPARAM pUserData)
{
- CJabberInfoFrameItem item(pszName);
- if (CJabberInfoFrameItem *pItem = m_pItems.find(&item))
+ if (m_pItems.find((CJabberInfoFrameItem*)&pszName))
return;
CJabberInfoFrameItem *newItem = new CJabberInfoFrameItem(pszName, bCompact, pUserData);
@@ -455,15 +454,13 @@ void CJabberInfoFrame::CreateInfoItem(char *pszName, bool bCompact, LPARAM pUser
void CJabberInfoFrame::SetInfoItemCallback(char *pszName, void (CJabberProto::*onEvent)(CJabberInfoFrame_Event *))
{
- CJabberInfoFrameItem item(pszName);
- if (CJabberInfoFrameItem *pItem = m_pItems.find(&item))
+ if (CJabberInfoFrameItem *pItem = m_pItems.find((CJabberInfoFrameItem*)&pszName))
pItem->m_onEvent = onEvent;
}
void CJabberInfoFrame::UpdateInfoItem(char *pszName, HANDLE hIcolibIcon, TCHAR *pszText)
{
- CJabberInfoFrameItem item(pszName);
- if (CJabberInfoFrameItem *pItem = m_pItems.find(&item))
+ if (CJabberInfoFrameItem *pItem = m_pItems.find((CJabberInfoFrameItem*)&pszName))
pItem->SetInfo(hIcolibIcon, pszText);
if (m_hwnd)
RedrawWindow(m_hwnd, NULL, NULL, RDW_INVALIDATE);