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 --- protocols/JabberG/src/jabber_adhoc.cpp | 2 +- protocols/JabberG/src/jabber_captcha.cpp | 5 ++- protocols/JabberG/src/jabber_chat.cpp | 6 ++-- protocols/JabberG/src/jabber_console.cpp | 14 ++++---- protocols/JabberG/src/jabber_form.cpp | 2 +- protocols/JabberG/src/jabber_frame.cpp | 6 ++-- protocols/JabberG/src/jabber_groupchat.cpp | 2 +- protocols/JabberG/src/jabber_icolib.cpp | 16 +-------- protocols/JabberG/src/jabber_opt.cpp | 57 ++++++++++++++---------------- protocols/JabberG/src/jabber_password.cpp | 2 +- protocols/JabberG/src/jabber_privacy.cpp | 8 ++--- protocols/JabberG/src/jabber_treelist.cpp | 2 +- protocols/JabberG/src/jabber_userinfo.cpp | 7 ++-- protocols/JabberG/src/jabber_xstatus.cpp | 2 +- protocols/JabberG/src/stdafx.h | 19 +++------- 15 files changed, 60 insertions(+), 90 deletions(-) (limited to 'protocols/JabberG/src') diff --git a/protocols/JabberG/src/jabber_adhoc.cpp b/protocols/JabberG/src/jabber_adhoc.cpp index e18b14207d..1c2c64c15d 100644 --- a/protocols/JabberG/src/jabber_adhoc.cpp +++ b/protocols/JabberG/src/jabber_adhoc.cpp @@ -494,7 +494,7 @@ static INT_PTR CALLBACK JabberAdHoc_CommandDlgProc(HWND hwndDlg, UINT msg, WPARA case WM_DESTROY: JabberFormDestroyUI(GetDlgItem(hwndDlg, IDC_FRAME)); - WindowFreeIcon(hwndDlg); + Window_FreeIcon_IcoLib(hwndDlg); dat->proto->m_hwndCommandWindow = NULL; mir_free(dat->ResponderJID); diff --git a/protocols/JabberG/src/jabber_captcha.cpp b/protocols/JabberG/src/jabber_captcha.cpp index 607bb047a2..5119579a86 100644 --- a/protocols/JabberG/src/jabber_captcha.cpp +++ b/protocols/JabberG/src/jabber_captcha.cpp @@ -44,8 +44,7 @@ INT_PTR CALLBACK JabberCaptchaFormDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, switch (msg) { case WM_INITDIALOG: { TranslateDialogDefault(hwndDlg); - SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_LoadIcon(IDI_KEYS, true)); - SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_LoadIcon(IDI_KEYS)); + Window_SetSkinIcon_IcoLib(hwndDlg, IDI_KEYS); params = (CAPTCHA_FORM_PARAMS*)lParam; LPCTSTR hint = params->hint; @@ -104,7 +103,7 @@ INT_PTR CALLBACK JabberCaptchaFormDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, break; case WM_DESTROY: - WindowFreeIcon(hwndDlg); + Window_FreeIcon_IcoLib(hwndDlg); break; } return FALSE; diff --git a/protocols/JabberG/src/jabber_chat.cpp b/protocols/JabberG/src/jabber_chat.cpp index 23bfb6e3f0..be0f1efadf 100644 --- a/protocols/JabberG/src/jabber_chat.cpp +++ b/protocols/JabberG/src/jabber_chat.cpp @@ -976,9 +976,9 @@ static INT_PTR CALLBACK sttUserInfoDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam break; case WM_DESTROY: - WindowFreeIcon(hwndDlg); - g_ReleaseIcon((HICON)SendDlgItemMessage(hwndDlg, IDC_BTN_AFFILIATION, BM_SETIMAGE, IMAGE_ICON, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(hwndDlg, IDC_BTN_ROLE, BM_SETIMAGE, IMAGE_ICON, 0)); + Window_FreeIcon_IcoLib(hwndDlg); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(hwndDlg, IDC_BTN_AFFILIATION, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(hwndDlg, IDC_BTN_ROLE, BM_SETIMAGE, IMAGE_ICON, 0)); if (dat) { SetWindowLongPtr(hwndDlg, GWLP_USERDATA, 0); mir_free(dat); diff --git a/protocols/JabberG/src/jabber_console.cpp b/protocols/JabberG/src/jabber_console.cpp index 9b55445cd9..721fed6aac 100644 --- a/protocols/JabberG/src/jabber_console.cpp +++ b/protocols/JabberG/src/jabber_console.cpp @@ -380,7 +380,7 @@ void CJabberDlgConsole::OnInitDialog() for (int i=0; i < _countof(filter_modes); i++) if (filter_modes[i].type == m_proto->m_filterInfo.type) { - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, (LPARAM)m_proto->LoadIconEx(filter_modes[i].icon))); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, (LPARAM)m_proto->LoadIconEx(filter_modes[i].icon))); SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, (LPARAM)m_proto->LoadIconEx(filter_modes[i].icon)); break; } @@ -406,11 +406,11 @@ void CJabberDlgConsole::OnClose() void CJabberDlgConsole::OnDestroy() { - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_MSG, BM_SETIMAGE, IMAGE_ICON, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_PRESENCE, BM_SETIMAGE, IMAGE_ICON, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_IQ, BM_SETIMAGE, IMAGE_ICON, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER_REFRESH, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_MSG, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_PRESENCE, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_IQ, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER_REFRESH, BM_SETIMAGE, IMAGE_ICON, 0)); m_proto->m_pDlgConsole = NULL; CSuper::OnDestroy(); @@ -580,7 +580,7 @@ INT_PTR CJabberDlgConsole::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) m_proto->m_filterInfo.type = (TFilterInfo::Type)(res - 1); for (i = 0; i < _countof(filter_modes); i++) { if (filter_modes[i].type == m_proto->m_filterInfo.type) { - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, (LPARAM)m_proto->LoadIconEx(filter_modes[i].icon))); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BTN_FILTER, BM_SETIMAGE, IMAGE_ICON, (LPARAM)m_proto->LoadIconEx(filter_modes[i].icon))); break; } } diff --git a/protocols/JabberG/src/jabber_form.cpp b/protocols/JabberG/src/jabber_form.cpp index e871ca0eb2..c8ad8a03b7 100644 --- a/protocols/JabberG/src/jabber_form.cpp +++ b/protocols/JabberG/src/jabber_form.cpp @@ -376,7 +376,7 @@ TJabberFormControlInfo *JabberFormAppendControl(HWND hwndStatic, TJabberFormLayo return item; } -void JabberFormAddListItem(TJabberFormControlInfo *item, const TCHAR *text, bool selected) +static void JabberFormAddListItem(TJabberFormControlInfo *item, const TCHAR *text, bool selected) { DWORD dwIndex; switch (item->type) { diff --git a/protocols/JabberG/src/jabber_frame.cpp b/protocols/JabberG/src/jabber_frame.cpp index 2703d09625..d6bf5afce7 100644 --- a/protocols/JabberG/src/jabber_frame.cpp +++ b/protocols/JabberG/src/jabber_frame.cpp @@ -364,7 +364,7 @@ void CJabberInfoFrame::PaintCompact(HDC hdc) HICON hIcon = IcoLib_GetIconByHandle(item.m_hIcolibIcon); if (hIcon) { DrawIconEx(hdc, SZ_FRAMEPADDING, (rc.bottom-cy_icon)/2, hIcon, cx_icon, cy_icon, 0, NULL, DI_NORMAL); - g_ReleaseIcon(hIcon); + IcoLib_ReleaseIcon(hIcon); } } @@ -379,7 +379,7 @@ void CJabberInfoFrame::PaintCompact(HDC hdc) DrawIconEx(hdc, cx, (rc.bottom-cy_icon)/2, hIcon, cx_icon, cy_icon, 0, NULL, DI_NORMAL); cx -= cx_icon; - g_ReleaseIcon(hIcon); + IcoLib_ReleaseIcon(hIcon); SetToolTip(item.m_tooltipId, &item.m_rcItem, item.m_pszText); } @@ -424,7 +424,7 @@ void CJabberInfoFrame::PaintNormal(HDC hdc) DrawIconEx(hdc, cx, cy + (line_height-cy_icon)/2, hIcon, cx_icon, cy_icon, 0, NULL, DI_NORMAL); cx += cx_icon + SZ_ICONSPACING; - g_ReleaseIcon(hIcon); + IcoLib_ReleaseIcon(hIcon); } } diff --git a/protocols/JabberG/src/jabber_groupchat.cpp b/protocols/JabberG/src/jabber_groupchat.cpp index 5f15f762f1..348f62bfda 100644 --- a/protocols/JabberG/src/jabber_groupchat.cpp +++ b/protocols/JabberG/src/jabber_groupchat.cpp @@ -479,7 +479,7 @@ void CJabberDlgGcJoin::OnInitDialog() void CJabberDlgGcJoin::OnDestroy() { - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BOOKMARKS, BM_SETIMAGE, IMAGE_ICON, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_BOOKMARKS, BM_SETIMAGE, IMAGE_ICON, 0)); m_proto->m_pDlgJabberJoinGroupchat = NULL; DeleteObject((HFONT)SendDlgItemMessage(m_hwnd, IDC_TXT_RECENT, WM_GETFONT, 0, 0)); diff --git a/protocols/JabberG/src/jabber_icolib.cpp b/protocols/JabberG/src/jabber_icolib.cpp index 1db364b465..01361f011c 100644 --- a/protocols/JabberG/src/jabber_icolib.cpp +++ b/protocols/JabberG/src/jabber_icolib.cpp @@ -552,26 +552,12 @@ HICON g_LoadIconEx(const char* name, bool big) return IcoLib_GetIcon(szSettingName, big); } -void g_ReleaseIcon(HICON hIcon) -{ - if (hIcon) - IcoLib_ReleaseIcon(hIcon); -} - void ImageList_AddIcon_Icolib(HIMAGELIST hIml, HICON hIcon) { ImageList_AddIcon(hIml, hIcon); - g_ReleaseIcon(hIcon); + IcoLib_ReleaseIcon(hIcon); } void WindowSetIcon(HWND hWnd, CJabberProto *proto, const char* name) { - SendMessage(hWnd, WM_SETICON, ICON_BIG, (LPARAM)proto->LoadIconEx(name, true)); - SendMessage(hWnd, WM_SETICON, ICON_SMALL, (LPARAM)proto->LoadIconEx(name)); -} - -void WindowFreeIcon(HWND hWnd) -{ - g_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_BIG, 0)); - g_ReleaseIcon((HICON)SendMessage(hWnd, WM_SETICON, ICON_SMALL, 0)); } diff --git a/protocols/JabberG/src/jabber_opt.cpp b/protocols/JabberG/src/jabber_opt.cpp index 8130aa286c..28e5f33660 100644 --- a/protocols/JabberG/src/jabber_opt.cpp +++ b/protocols/JabberG/src/jabber_opt.cpp @@ -1393,45 +1393,42 @@ static INT_PTR CALLBACK JabberRosterOptDlgProc(HWND hwndDlg, UINT msg, WPARAM wP CJabberProto *ppro = (CJabberProto*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA); switch (msg) { + case WM_INITDIALOG: + ppro = (CJabberProto*)lParam; + SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam); + + TranslateDialogDefault(hwndDlg); + WindowSetIcon(hwndDlg, ppro, "Agents"); + + Utils_RestoreWindowPosition(hwndDlg, NULL, ppro->m_szModuleName, "rosterCtrlWnd_"); + + ListView_SetExtendedListViewStyle(GetDlgItem(hwndDlg, IDC_ROSTER), LVS_EX_CHECKBOXES | LVS_EX_BORDERSELECT /*| LVS_EX_FULLROWSELECT*/ | LVS_EX_GRIDLINES /*| LVS_EX_HEADERDRAGDROP*/); + mir_subclassWindow(GetDlgItem(hwndDlg, IDC_ROSTER), _RosterNewListProc); + _RosterListClear(hwndDlg); + ppro->rrud.hwndDlg = hwndDlg; + ppro->rrud.bReadyToDownload = TRUE; + ppro->rrud.bReadyToUpload = FALSE; + SendMessage(hwndDlg, JM_STATUSCHANGED, 0, 0); + return TRUE; + case JM_STATUSCHANGED: { int count = ListView_GetItemCount(GetDlgItem(hwndDlg, IDC_ROSTER)); EnableWindow(GetDlgItem(hwndDlg, IDC_DOWNLOAD), ppro->m_bJabberOnline); EnableWindow(GetDlgItem(hwndDlg, IDC_UPLOAD), count && ppro->m_bJabberOnline); EnableWindow(GetDlgItem(hwndDlg, IDC_EXPORT), count > 0); - break; - } - case WM_CLOSE: - { - DestroyWindow(hwndDlg); - break; - } - case WM_DESTROY: - { - Utils_SaveWindowPosition(hwndDlg, NULL, ppro->m_szModuleName, "rosterCtrlWnd_"); - ppro->rrud.hwndDlg = NULL; - WindowFreeIcon(hwndDlg); - break; } - case WM_INITDIALOG: - { - ppro = (CJabberProto*)lParam; - SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam); - - TranslateDialogDefault(hwndDlg); - WindowSetIcon(hwndDlg, ppro, "Agents"); + break; - Utils_RestoreWindowPosition(hwndDlg, NULL, ppro->m_szModuleName, "rosterCtrlWnd_"); + case WM_CLOSE: + DestroyWindow(hwndDlg); + break; - ListView_SetExtendedListViewStyle(GetDlgItem(hwndDlg, IDC_ROSTER), LVS_EX_CHECKBOXES | LVS_EX_BORDERSELECT /*| LVS_EX_FULLROWSELECT*/ | LVS_EX_GRIDLINES /*| LVS_EX_HEADERDRAGDROP*/); - mir_subclassWindow(GetDlgItem(hwndDlg, IDC_ROSTER), _RosterNewListProc); - _RosterListClear(hwndDlg); - ppro->rrud.hwndDlg = hwndDlg; - ppro->rrud.bReadyToDownload = TRUE; - ppro->rrud.bReadyToUpload = FALSE; - SendMessage(hwndDlg, JM_STATUSCHANGED, 0, 0); - } - return TRUE; + case WM_DESTROY: + Utils_SaveWindowPosition(hwndDlg, NULL, ppro->m_szModuleName, "rosterCtrlWnd_"); + ppro->rrud.hwndDlg = NULL; + Window_FreeIcon_IcoLib(hwndDlg); + break; case WM_GETMINMAXINFO: { diff --git a/protocols/JabberG/src/jabber_password.cpp b/protocols/JabberG/src/jabber_password.cpp index 3ca63f9121..4fe3ae4ab0 100644 --- a/protocols/JabberG/src/jabber_password.cpp +++ b/protocols/JabberG/src/jabber_password.cpp @@ -90,7 +90,7 @@ static INT_PTR CALLBACK JabberChangePasswordDlgProc(HWND hwndDlg, UINT msg, WPAR break; case WM_DESTROY: ppro->m_hwndJabberChangePassword = NULL; - WindowFreeIcon(hwndDlg); + Window_FreeIcon_IcoLib(hwndDlg); break; } diff --git a/protocols/JabberG/src/jabber_privacy.cpp b/protocols/JabberG/src/jabber_privacy.cpp index 0f56b27c7a..3dd5805f00 100644 --- a/protocols/JabberG/src/jabber_privacy.cpp +++ b/protocols/JabberG/src/jabber_privacy.cpp @@ -545,10 +545,10 @@ public: void OnDestroy() { - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_MESSAGE, STM_SETICON, 0, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_QUERY, STM_SETICON, 0, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_PRESENCEIN, STM_SETICON, 0, 0)); - g_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_PRESENCEOUT, STM_SETICON, 0, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_MESSAGE, STM_SETICON, 0, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_QUERY, STM_SETICON, 0, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_PRESENCEIN, STM_SETICON, 0, 0)); + IcoLib_ReleaseIcon((HICON)SendDlgItemMessage(m_hwnd, IDC_ICO_PRESENCEOUT, STM_SETICON, 0, 0)); m_proto->m_hwndPrivacyRule = NULL; } }; diff --git a/protocols/JabberG/src/jabber_treelist.cpp b/protocols/JabberG/src/jabber_treelist.cpp index ea66936cad..33d0acf232 100644 --- a/protocols/JabberG/src/jabber_treelist.cpp +++ b/protocols/JabberG/src/jabber_treelist.cpp @@ -249,7 +249,7 @@ int TreeList_AddIcon(HWND hwnd, HICON hIcon, int iOverlay) { HIMAGELIST hIml = ListView_GetImageList(hwnd, LVSIL_SMALL); int idx = ImageList_AddIcon(hIml, hIcon); - g_ReleaseIcon(hIcon); + IcoLib_ReleaseIcon(hIcon); if (iOverlay) ImageList_SetOverlayImage(hIml, idx, iOverlay); return idx; } diff --git a/protocols/JabberG/src/jabber_userinfo.cpp b/protocols/JabberG/src/jabber_userinfo.cpp index 380e1c05ad..7601a92287 100644 --- a/protocols/JabberG/src/jabber_userinfo.cpp +++ b/protocols/JabberG/src/jabber_userinfo.cpp @@ -190,7 +190,7 @@ static HTREEITEM sttFillInfoLine(HWND hwndTree, HTREEITEM htiRoot, HICON hIcon, tvis.itemex.mask |= TVIF_IMAGE|TVIF_SELECTEDIMAGE; tvis.itemex.iImage = tvis.itemex.iSelectedImage = ImageList_AddIcon(himl, hIcon); - g_ReleaseIcon(hIcon); + IcoLib_ReleaseIcon(hIcon); } if (hti) { @@ -439,8 +439,7 @@ static INT_PTR CALLBACK JabberUserInfoDlgProc(HWND hwndDlg, UINT msg, WPARAM wPa // lParam is hContact TranslateDialogDefault(hwndDlg); - SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_LoadIcon(SKINICON_OTHER_USERDETAILS, true)); - SendMessage(hwndDlg, WM_SETICON, ICON_SMALL, (LPARAM)Skin_LoadIcon(SKINICON_OTHER_USERDETAILS)); + Window_SetSkinIcon_IcoLib(hwndDlg, SKINICON_OTHER_USERDETAILS); dat = (JabberUserInfoDlgData *)mir_alloc(sizeof(JabberUserInfoDlgData)); memset(dat, 0, sizeof(JabberUserInfoDlgData)); @@ -585,7 +584,7 @@ static INT_PTR CALLBACK JabberUserInfoDlgProc(HWND hwndDlg, UINT msg, WPARAM wPa } WindowList_Remove(hUserInfoList, hwndDlg); ImageList_Destroy(TreeView_SetImageList(GetDlgItem(hwndDlg, IDC_TV_INFO), NULL, TVSIL_NORMAL)); - WindowFreeIcon(hwndDlg); + Window_FreeIcon_IcoLib(hwndDlg); break; } return FALSE; diff --git a/protocols/JabberG/src/jabber_xstatus.cpp b/protocols/JabberG/src/jabber_xstatus.cpp index a4ac9974ed..e654238361 100644 --- a/protocols/JabberG/src/jabber_xstatus.cpp +++ b/protocols/JabberG/src/jabber_xstatus.cpp @@ -155,7 +155,7 @@ private: bool m_subitem; CStatusMode(LPARAM id, char *name, HICON hIcon, TCHAR *title, bool subitem): m_id(id), m_name(name), m_hIcon(hIcon), m_title(title), m_subitem(subitem) {} - ~CStatusMode() { g_ReleaseIcon(m_hIcon); } + ~CStatusMode() { IcoLib_ReleaseIcon(m_hIcon); } }; OBJLIST m_modes; diff --git a/protocols/JabberG/src/stdafx.h b/protocols/JabberG/src/stdafx.h index b625d69ecd..429ec8f418 100644 --- a/protocols/JabberG/src/stdafx.h +++ b/protocols/JabberG/src/stdafx.h @@ -624,7 +624,6 @@ LPARAM TreeList_GetData(HTREELISTITEM hItem); HTREELISTITEM TreeList_GetRoot(HWND hwnd); int TreeList_GetChildrenCount(HTREELISTITEM hItem); HTREELISTITEM TreeList_GetChild(HTREELISTITEM hItem, int i); -void sttTreeList_RecursiveApply(HTREELISTITEM hItem, void (*func)(HTREELISTITEM, LPARAM), LPARAM data); void TreeList_Update(HWND hwnd); BOOL TreeList_ProcessMessage(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, UINT idc, BOOL *result); @@ -645,11 +644,8 @@ void JabberFormDestroyUI(HWND hwndStatic); void JabberFormSetInstruction(HWND hwndForm, const TCHAR *text); HJFORMLAYOUT JabberFormCreateLayout(HWND hwndStatic); // use mir_free to destroy HJFORMCTRL JabberFormAppendControl(HWND hwndStatic, HJFORMLAYOUT layout_info, TJabberFormControlType type, const TCHAR *labelStr, const TCHAR *valueStr); -void JabberFormAddListItem(HJFORMCTRL item, const TCHAR *text, bool selected); void JabberFormLayoutControls(HWND hwndStatic, HJFORMLAYOUT layout_info, int *formHeight); -void JabberFormCreateDialog(HXML xNode, TCHAR* defTitle, JABBER_FORM_SUBMIT_FUNC pfnSubmit, void *userdata); - HXML JabberFormGetData(HWND hwndStatic, HXML xNode); //---- jabber_icolib.c ---------------------------------------------- @@ -658,13 +654,9 @@ void g_IconsInit(); void g_XstatusIconsInit(); HANDLE g_GetIconHandle(int iconId); HICON g_LoadIconEx(const char* name, bool big = false); -void g_ReleaseIcon(HICON hIcon); void ImageList_AddIcon_Icolib(HIMAGELIST hIml, HICON hIcon); void WindowSetIcon(HWND hWnd, CJabberProto *proto, const char* name); -void WindowFreeIcon(HWND hWnd); - -int ReloadIconsEventHook(WPARAM wParam, LPARAM lParam); //---- jabber_libstr.c ---------------------------------------------- @@ -729,7 +721,7 @@ struct TStringPairs const char* operator[](const char* name) const; int numElems; - TStringPairsElem* elems; + TStringPairsElem *elems; }; typedef char JabberShaStrBuf[2*MIR_SHA1_HASH_SIZE + 1]; @@ -753,9 +745,9 @@ LPCTSTR __stdcall JabberGetPictureType(HXML node, const char *picBuf); TCHAR* time2str(time_t _time, TCHAR *buf, size_t bufLen); time_t str2time(const TCHAR*); -const TCHAR *JabberStrIStr(const TCHAR *str, const TCHAR *substr); -void JabberCopyText(HWND hwnd, const TCHAR *text); -CJabberProto *JabberChooseInstance(bool bIsLink=false); +const TCHAR* JabberStrIStr(const TCHAR *str, const TCHAR *substr); +void JabberCopyText(HWND hwnd, const TCHAR *text); +CJabberProto* JabberChooseInstance(bool bIsLink=false); bool JabberReadXep203delay(HXML node, time_t &msgTime); @@ -766,7 +758,4 @@ void UIShowControls(HWND hwndDlg, int *idList, int nCmdShow); void JabberUserInfoUpdate(MCONTACT hContact); -//---- jabber_iq_handlers.cpp -BOOL GetOSDisplayString(LPTSTR pszOS, int BUFSIZE); - #endif -- cgit v1.2.3