From 23e6fe719ec331e47548e72c00883b8192b8c3fb Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 12 Apr 2015 14:19:40 +0000 Subject: unneeded object creation removed git-svn-id: http://svn.miranda-ng.org/main/trunk@12774 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/JabberG/src/jabber_frame.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'protocols') 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); -- cgit v1.2.3