diff options
author | pescuma <pescuma@c086bb3d-8645-0410-b8da-73a8550f86e7> | 2008-04-26 23:11:12 +0000 |
---|---|---|
committer | pescuma <pescuma@c086bb3d-8645-0410-b8da-73a8550f86e7> | 2008-04-26 23:11:12 +0000 |
commit | d052a59d5fbbdd17035ed92fee43932381a1e5c9 (patch) | |
tree | 6db5b377dde18a142d441ba53618b959a3d28850 /Plugins/emoticons/selwin.cpp | |
parent | 97a1ad6aa3f9696313a6d1e2e073b1e08a6b5682 (diff) |
Handle metacontact change in the middle of chat
Works with miranda 0.7
Version bump: 0.0.2.4
git-svn-id: http://pescuma.googlecode.com/svn/trunk/Miranda@89 c086bb3d-8645-0410-b8da-73a8550f86e7
Diffstat (limited to 'Plugins/emoticons/selwin.cpp')
-rw-r--r-- | Plugins/emoticons/selwin.cpp | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/Plugins/emoticons/selwin.cpp b/Plugins/emoticons/selwin.cpp index d0f7301..2bfe5f2 100644 --- a/Plugins/emoticons/selwin.cpp +++ b/Plugins/emoticons/selwin.cpp @@ -73,19 +73,6 @@ void AssertInsideScreen(RECT &rc) }
-DWORD ConvertServiceParam(EmoticonsSelectionLayout *layout, char *param)
-{
- DWORD ret;
- if (param == NULL)
- ret = 0;
- else if (stricmp("hContact", param) == 0)
- ret = (DWORD) layout->ssd->hContact;
- else
- ret = atoi(param);
- return ret;
-}
-
-
INT_PTR CALLBACK EmoticonSeletionDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
switch(msg)
@@ -284,12 +271,12 @@ INT_PTR CALLBACK EmoticonSeletionDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPA if (layout->selection >= 0 && layout->ssd->hwndTarget != NULL)
{
Emoticon *e = layout->ssd->module->emoticons[layout->selection];
-
if (e->service[0] != NULL)
{
- CallProtoService(layout->ssd->module->name, e->service[0],
- ConvertServiceParam(layout, e->service[1]),
- ConvertServiceParam(layout, e->service[2]));
+ if (e->service[3] != NULL && EmoticonServiceExists(layout->ssd->module->name, e->service[3]))
+ CallEmoticonService(layout->ssd->module->name, layout->ssd->hContact, e->service[3], e->service[4], e->service[5]);
+ else
+ CallEmoticonService(layout->ssd->module->name, layout->ssd->hContact, e->service[0], e->service[1], e->service[2]);
}
else if (opts.only_replace_isolated)
{
|