From eec361608fde60d63fe4511e26e3b95c7f72be13 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 5 Jun 2016 16:11:08 +0000 Subject: - fix for #1059; - direct unsafe work with icons replaces with Window_SetIcon_IcoLib / Window_SetSkinIcon_IcoLib; - code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@16917 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/core/stdmsg/src/msgdialog.cpp | 6 ++---- src/core/stdmsg/src/msgs.h | 1 + src/core/stdmsg/src/msgtimedout.cpp | 4 +--- 3 files changed, 4 insertions(+), 7 deletions(-) (limited to 'src/core/stdmsg') diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index 22bf436713..9e43d2cf48 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -909,13 +909,11 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l if (dat->szProto) { WORD wStatus = db_get_w(dat->hContact, dat->szProto, "Status", ID_STATUS_OFFLINE); - SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_LoadProtoIcon(dat->szProto, wStatus, true)); - SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_LoadProtoIcon(dat->szProto, wStatus)); + Window_SetProtoIcon_IcoLib(hwndDlg, dat->szProto, wStatus); break; } } - SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_LoadIcon(SKINICON_EVENT_MESSAGE, true)); - SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_LoadIcon(SKINICON_EVENT_MESSAGE)); + Window_SetSkinIcon_IcoLib(hwndDlg, SKINICON_EVENT_MESSAGE); break; case DM_USERNAMETOCLIP: diff --git a/src/core/stdmsg/src/msgs.h b/src/core/stdmsg/src/msgs.h index 31a1c643cf..ac5c99a003 100644 --- a/src/core/stdmsg/src/msgs.h +++ b/src/core/stdmsg/src/msgs.h @@ -127,6 +127,7 @@ int DbEventIsForMsgWindow(DBEVENTINFO *dbei); int DbEventIsShown(DBEVENTINFO *dbei); void StreamInEvents(HWND hwndDlg, MEVENT hDbEventFirst, int count, int fAppend); int SendMessageDirect(const TCHAR *szMsg, MCONTACT hContact, char *szProto); +INT_PTR SendMessageCmd(MCONTACT hContact, char *msg, int isWchar); void LoadMsgLogIcons(void); void FreeMsgLogIcons(void); diff --git a/src/core/stdmsg/src/msgtimedout.cpp b/src/core/stdmsg/src/msgtimedout.cpp index 187bc43f41..0f3d4ac508 100644 --- a/src/core/stdmsg/src/msgtimedout.cpp +++ b/src/core/stdmsg/src/msgtimedout.cpp @@ -28,9 +28,7 @@ struct ErrorDlgParam TMsgQueue *item; }; -INT_PTR SendMessageCmd(MCONTACT hContact, char* msg, int isWchar); - -static INT_PTR CALLBACK ErrorDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) +INT_PTR CALLBACK ErrorDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) { TMsgQueue *item = (TMsgQueue*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA); -- cgit v1.2.3