summaryrefslogtreecommitdiff
path: root/src/mir_app
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2017-07-10 20:23:58 +0300
committerGeorge Hazan <ghazan@miranda.im>2017-07-10 20:23:58 +0300
commit0f5d6891e9a94f592a799d83fdbc79cbe36b8734 (patch)
tree977e2d03cff8475435ccbb49e64159bd816faaac /src/mir_app
parenta2e38963a647f9f58ff276d2ad9f89f7202c47eb (diff)
fixes #757 (Scriver: send message by Enter don't work until restart)
Diffstat (limited to 'src/mir_app')
-rw-r--r--src/mir_app/src/chat.h3
-rw-r--r--src/mir_app/src/pluginopts.cpp6
-rw-r--r--src/mir_app/src/srmm_toolbar.cpp2
3 files changed, 9 insertions, 2 deletions
diff --git a/src/mir_app/src/chat.h b/src/mir_app/src/chat.h
index 136ea36752..444aa25fd8 100644
--- a/src/mir_app/src/chat.h
+++ b/src/mir_app/src/chat.h
@@ -100,6 +100,9 @@ void LoadChatIcons(void);
int LoadChatModule(void);
void UnloadChatModule(void);
+// srmm_toolbar.cpp
+void CALLBACK SrmmLoadToolbar();
+
// tools.c
int DoRtfToTags(CMStringW &pszText, int iNumColors, COLORREF *pColors);
wchar_t *RemoveFormatting(const wchar_t* pszText);
diff --git a/src/mir_app/src/pluginopts.cpp b/src/mir_app/src/pluginopts.cpp
index 73c980c3cf..c31e5c4816 100644
--- a/src/mir_app/src/pluginopts.cpp
+++ b/src/mir_app/src/pluginopts.cpp
@@ -26,9 +26,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include <m_version.h>
+#include "chat.h"
#include "plugins.h"
-extern MUUID miid_clist, miid_database, miid_protocol;
+extern MUUID miid_clist, miid_database, miid_protocol, miid_srmm;
HANDLE hevLoadModule, hevUnloadModule;
static bool bOldMode = false;
@@ -200,6 +201,9 @@ static bool LoadPluginDynamically(PluginListItemData *dat)
if (CallPluginEventHook(pPlug->bpi.hInst, hModulesLoadedEvent, 0, 0) != 0)
goto LBL_Error;
+ if (hasMuuid(pPlug->bpi, miid_srmm))
+ SrmmLoadToolbar();
+
dat->hInst = pPlug->bpi.hInst;
NotifyFastHook(hevLoadModule, (WPARAM)pPlug->bpi.pluginInfo, (LPARAM)pPlug->bpi.hInst);
return true;
diff --git a/src/mir_app/src/srmm_toolbar.cpp b/src/mir_app/src/srmm_toolbar.cpp
index 2cf4504354..8a23b50565 100644
--- a/src/mir_app/src/srmm_toolbar.cpp
+++ b/src/mir_app/src/srmm_toolbar.cpp
@@ -779,7 +779,7 @@ static int SrmmModulesLoaded(WPARAM, LPARAM)
return 0;
}
-static void CALLBACK SrmmLoadToolbar()
+void CALLBACK SrmmLoadToolbar()
{
NotifyEventHooks(hHookToolBarLoadedEvt, 0, 0);
}