From 3c9203dbd3676b11b39277e0e6ee28eb6d9f2a39 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 16 Jan 2024 17:09:39 +0300 Subject: this code is also not needed... --- plugins/Clist_modern/src/modern_clui.cpp | 23 ----------------------- plugins/Clist_modern/src/modern_clui.h | 2 -- 2 files changed, 25 deletions(-) (limited to 'plugins') diff --git a/plugins/Clist_modern/src/modern_clui.cpp b/plugins/Clist_modern/src/modern_clui.cpp index 81d6e5ff6e..c93412404d 100644 --- a/plugins/Clist_modern/src/modern_clui.cpp +++ b/plugins/Clist_modern/src/modern_clui.cpp @@ -2392,29 +2392,6 @@ LRESULT CLUI::OnNotify(UINT msg, WPARAM wParam, LPARAM lParam) return DefCluiWndProc(msg, wParam, lParam); } -LRESULT CLUI::OnContextMenu(UINT, WPARAM, LPARAM lParam) -{ - POINT pt = UNPACK_POINT(lParam); - // x/y might be -1 if it was generated by a kb click - RECT rc; - GetWindowRect(g_clistApi.hwndContactTree, &rc); - if (pt.x == -1 && pt.y == -1) { - // all this is done in screen-coords! - GetCursorPos(&pt); - // the mouse isnt near the window, so put it in the middle of the window - if (!PtInRect(&rc, pt)) { - pt.x = rc.left + (rc.right - rc.left) / 2; - pt.y = rc.top + (rc.bottom - rc.top) / 2; - } - } - if (PtInRect(&rc, pt)) { - HMENU hMenu = Menu_BuildGroupMenu(); - TrackPopupMenu(hMenu, TPM_TOPALIGN | TPM_LEFTALIGN | TPM_LEFTBUTTON, pt.x, pt.y, 0, m_hWnd, nullptr); - Menu_DestroyNestedMenu(hMenu); - } - return FALSE; -} - LRESULT CLUI::OnMeasureItem(UINT, WPARAM, LPARAM lParam) { LPMEASUREITEMSTRUCT pmis = (LPMEASUREITEMSTRUCT)lParam; diff --git a/plugins/Clist_modern/src/modern_clui.h b/plugins/Clist_modern/src/modern_clui.h index e1c0efcd2c..b32f677d5d 100644 --- a/plugins/Clist_modern/src/modern_clui.h +++ b/plugins/Clist_modern/src/modern_clui.h @@ -104,7 +104,6 @@ public: HANDLE_MESSAGE(WM_GETMINMAXINFO, OnGetMinMaxInfo); HANDLE_MESSAGE(WM_MOVING, OnMoving); HANDLE_MESSAGE(WM_NOTIFY, OnNotify); - HANDLE_MESSAGE(WM_CONTEXTMENU, OnContextMenu); HANDLE_MESSAGE(WM_MEASUREITEM, OnMeasureItem); HANDLE_MESSAGE(WM_DRAWITEM, OnDrawItem); HANDLE_MESSAGE(WM_DESTROY, OnDestroy); @@ -171,7 +170,6 @@ private: LRESULT OnNotify(UINT msg, WPARAM wParam, LPARAM lParam); LRESULT OnListSizeChangeNotify(NMCLISTCONTROL *pnmc); LRESULT OnClickNotify(NMCLISTCONTROL *pnmc); - LRESULT OnContextMenu(UINT msg, WPARAM wParam, LPARAM lParam); LRESULT OnMeasureItem(UINT msg, WPARAM wParam, LPARAM lParam); LRESULT OnDrawItem(UINT msg, WPARAM wParam, LPARAM lParam); LRESULT OnDestroy(UINT msg, WPARAM wParam, LPARAM lParam); -- cgit v1.2.3