From 2bbcdb330bbf4d3bbd636f7014ee447c9be95495 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 11 Jul 2012 21:12:00 +0000 Subject: fix for a TTB to remove buttons of the dynamically unloaded plugins git-svn-id: http://svn.miranda-ng.org/main/trunk@911 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/modules/plugins/newplugins.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/modules/plugins') diff --git a/src/modules/plugins/newplugins.cpp b/src/modules/plugins/newplugins.cpp index cfccdfaf62..6b2eb6d63a 100644 --- a/src/modules/plugins/newplugins.cpp +++ b/src/modules/plugins/newplugins.cpp @@ -127,6 +127,19 @@ char* GetPluginNameByInstance(HINSTANCE hInstance) return NULL; } +int GetPluginLangByInstance(HINSTANCE hInstance) +{ + if (pluginList.getCount() == 0) + return NULL; + + for (int i=0; i < pluginList.getCount(); i++) { + pluginEntry* p = pluginList[i]; + if (p->bpi.pluginInfo && p->bpi.hInst == hInstance) + return p->hLangpack; + } + return NULL; +} + int GetPluginFakeId(const MUUID &uuid, int hLangpack) { for (int i=0; i < pluginList.getCount(); i++) { -- cgit v1.2.3