diff options
author | George Hazan <ghazan@miranda.im> | 2019-04-13 20:22:59 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-04-13 20:22:59 +0300 |
commit | 680873487c4a7987012606119a744e5ca725ad30 (patch) | |
tree | 8e5fbc68a253c3ec44287754c9295670f1ee44c3 /include/newpluginapi.h | |
parent | 6c4136504c660bf3359e6641362672c4b9502be5 (diff) |
merge with trunk
Diffstat (limited to 'include/newpluginapi.h')
-rw-r--r-- | include/newpluginapi.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/newpluginapi.h b/include/newpluginapi.h index 32ed951999..153da7936e 100644 --- a/include/newpluginapi.h +++ b/include/newpluginapi.h @@ -25,6 +25,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef M_NEWPLUGINAPI_H__
#define M_NEWPLUGINAPI_H__
+#if !defined(HIMAGELIST)
+typedef struct _IMAGELIST* HIMAGELIST;
+#endif
+
#include <m_core.h>
#include <m_database.h>
@@ -151,6 +155,8 @@ typedef int(*pfnUninitProto)(PROTO_INTERFACE*); #pragma warning(push)
#pragma warning(disable:4275)
+struct IcolibItem;
+
class MIR_APP_EXPORT CMPluginBase : public MNonCopyable
{
void tryOpenLog();
@@ -160,6 +166,7 @@ protected: const char *m_szModuleName;
const PLUGININFOEX &m_pInfo;
HANDLE m_hLogger = nullptr;
+ LIST<IcolibItem> m_arIcons;
CMPluginBase(const char *moduleName, const PLUGININFOEX &pInfo);
~CMPluginBase();
@@ -172,6 +179,12 @@ public: void debugLogA(LPCSTR szFormat, ...);
void debugLogW(LPCWSTR wszFormat, ...);
+ __forceinline void addIcolib(HANDLE hIcolib) { m_arIcons.insert((IcolibItem*)hIcolib); }
+ int addImgListIcon(HIMAGELIST himl, int iconId);
+ HICON getIcon(int iconId, bool big = false);
+ HANDLE getIconHandle(int iconId);
+ void releaseIcon(int iconId, bool big = false);
+
__forceinline const PLUGININFOEX& getInfo() const { return m_pInfo; }
__forceinline const char* getModule() const { return m_szModuleName; }
|