summaryrefslogtreecommitdiff
path: root/plugins/Quotes/src/ExtraImages.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Quotes/src/ExtraImages.cpp')
-rw-r--r--plugins/Quotes/src/ExtraImages.cpp40
1 files changed, 6 insertions, 34 deletions
diff --git a/plugins/Quotes/src/ExtraImages.cpp b/plugins/Quotes/src/ExtraImages.cpp
index 8b14ce5c4c..83f10fa4f3 100644
--- a/plugins/Quotes/src/ExtraImages.cpp
+++ b/plugins/Quotes/src/ExtraImages.cpp
@@ -1,31 +1,15 @@
#include "StdAfx.h"
-CExtraImages::CExtraImages() :
- m_hExtraIcons(ExtraIcon_Register(ICON_STR_QUOTE,QUOTES_PROTOCOL_NAME,Quotes_MakeIconName(ICON_STR_MAIN).c_str())),
- m_bExtraImagesInit(false)
-{
- m_ahExtraImages[eiUp] = INVALID_HANDLE_VALUE;
- m_ahExtraImages[eiDown] = INVALID_HANDLE_VALUE;
- m_ahExtraImages[eiNotChanged] = INVALID_HANDLE_VALUE;
-}
-
-CExtraImages::~CExtraImages()
-{
-}
+static HANDLE hExtraIcon;
-CExtraImages& CExtraImages::GetInstance()
+void Quotes_InitExtraIcons()
{
- static CExtraImages s_ei;
- return s_ei;
+ hExtraIcon = ExtraIcon_Register(ICON_STR_QUOTE, QUOTES_PROTOCOL_NAME, Quotes_MakeIconName(ICON_STR_MAIN).c_str());
}
-void CExtraImages::RebuildExtraImages()
+bool SetContactExtraImage(MCONTACT hContact,EImageIndex nIndex)
{
-}
-
-bool CExtraImages::SetContactExtraImage(MCONTACT hContact,EImageIndex nIndex)const
-{
- if (!m_hExtraIcons)
+ if (!hExtraIcon)
return false;
HANDLE hIcolib;
@@ -42,17 +26,5 @@ bool CExtraImages::SetContactExtraImage(MCONTACT hContact,EImageIndex nIndex)con
default:
hIcolib = NULL;
}
- return ExtraIcon_SetIcon(m_hExtraIcons, hContact, hIcolib) == 0;
+ return ExtraIcon_SetIcon(hExtraIcon, hContact, hIcolib) == 0;
}
-
-// int QuotesEventFunc_onExtraImageApply(WPARAM wp,LPARAM lp)
-// {
-// MCONTACT hContact = MCONTACT(wp);
-//
-// const CModuleInfo::TQuotesProvidersPtr& pProviders = CModuleInfo::GetQuoteProvidersPtr();
-// CQuotesProviders::TQuotesProviderPtr pProvider = pProviders->GetContactProviderPtr(hContact);
-// if(pProvider)
-// pProvider->SetContactExtraIcon(hContact);
-//
-// return 0;
-// }