diff options
author | George Hazan <ghazan@miranda.im> | 2019-03-08 15:29:44 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-03-08 15:29:44 +0300 |
commit | 99962115431435cf17dfae4d3b7c8d7d55d824bf (patch) | |
tree | 1c80a533f5d3d4ba9d3b894a9a38b9167fe3047e /protocols/ConnectionNotify/src | |
parent | a23186175cff579d5aeb231372e87b0b852bdb38 (diff) |
life is too short to remember whether this structure is zeroed or not
Diffstat (limited to 'protocols/ConnectionNotify/src')
-rw-r--r-- | protocols/ConnectionNotify/src/ConnectionNotify.cpp | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/protocols/ConnectionNotify/src/ConnectionNotify.cpp b/protocols/ConnectionNotify/src/ConnectionNotify.cpp index 9a2a3d5122..2ea63878f5 100644 --- a/protocols/ConnectionNotify/src/ConnectionNotify.cpp +++ b/protocols/ConnectionNotify/src/ConnectionNotify.cpp @@ -750,23 +750,12 @@ static LRESULT CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPA return DefWindowProc(hWnd, message, wParam, lParam); } - //show popup void showMsg(wchar_t *pName, DWORD pid, wchar_t *intIp, wchar_t *extIp, int intPort, int extPort, int state) { + struct CONNECTION *mpd = (struct CONNECTION*)mir_alloc(sizeof(struct CONNECTION)); POPUPDATAW ppd; - //hContact = A_VALID_HANDLE_YOU_GOT_FROM_SOMEWHERE; - //hIcon = A_VALID_HANDLE_YOU_GOT_SOMEWHERE; - //char * lpzContactName = (char*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)lhContact,0); - //99% of the times you'll just copy this line. - //1% of the times you may wish to change the contact's name. I don't know why you should, but you can. - //char * lpzText; - //The text for the second line. You could even make something like: char lpzText[128]; mir_wstrcpy(lpzText, "Hello world!"); It's your choice. - - struct CONNECTION *mpd = (struct CONNECTION*)mir_alloc(sizeof(struct CONNECTION)); - //MessageBox(NULL,"aaa","aaa",1); - memset(&ppd, 0, sizeof(ppd)); //This is always a good thing to do. ppd.lchContact = NULL;//(HANDLE)hContact; //Be sure to use a GOOD handle, since this will not be checked. ppd.lchIcon = LoadIcon(g_plugin.getInst(), MAKEINTRESOURCE(IDI_ICON1)); if (settingResolveIp) { |