reapack

Package manager for REAPER
Log | Files | Refs | Submodules | README | LICENSE

commit a8bf69168a8bb293c6081c7f423e18f7411dfd89
parent 4563f22444bec60d102982b43017aa1804e4f6e3
Author: cfillion <cfillion@users.noreply.github.com>
Date:   Wed, 29 Jun 2016 15:02:32 -0700

dialog: fix context menus being shown on the wrong monitor in some setups

partially fixes bug #6

Diffstat:
Msrc/dialog.cpp | 6+++++-
1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/dialog.cpp b/src/dialog.cpp @@ -25,6 +25,10 @@ #include <boost/algorithm/string/join.hpp> #include <reaper_plugin_functions.h> +#ifdef _WIN32 +#include <windowsx.h> +#endif + using namespace std; DialogMap Dialog::s_instances; @@ -75,7 +79,7 @@ WDL_DLGRET Dialog::Proc(HWND handle, UINT msg, WPARAM wParam, LPARAM lParam) dlg->onNotify((LPNMHDR)lParam, lParam); break; case WM_CONTEXTMENU: - dlg->onContextMenu((HWND)wParam, LOWORD(lParam), HIWORD(lParam)); + dlg->onContextMenu((HWND)wParam, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam)); break; case WM_GETMINMAXINFO: { MINMAXINFO *mmi = (MINMAXINFO *)lParam;