X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=winboard%2Fwinboard.c;h=11a5d28a01a07956f7299de34320fcd8cd305663;hb=e62d77e7d17ec2bad73953355fba650afa68f58e;hp=e37c62948da936b67e64e40264b5b7208ee81137;hpb=35eff6783ec3d1809b70948ab5ffc475bcec7980;p=xboard.git diff --git a/winboard/winboard.c b/winboard/winboard.c index e37c629..11a5d28 100644 --- a/winboard/winboard.c +++ b/winboard/winboard.c @@ -6901,7 +6901,8 @@ ConsoleTextSubclass(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) SendMessage(hInput, message, wParam, lParam); } return 0; - } // [HGM] navigate: for Ctrl+R, flow into nex case (moved up here) to summon up menu + } // [HGM] navigate: for Ctrl+R, flow into next case (moved up here) to summon up menu + lParam = -1; case WM_RBUTTONDOWN: if (!(GetKeyState(VK_SHIFT) & ~1)) { /* Move selection here if it was empty */ @@ -6910,7 +6911,7 @@ ConsoleTextSubclass(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) pt.y = HIWORD(lParam); SendMessage(hwnd, EM_EXGETSEL, 0, (LPARAM)&sel); if (sel.cpMin == sel.cpMax) { - sel.cpMin = SendMessage(hwnd, EM_CHARFROMPOS, 0, (LPARAM)&pt); /*doc is wrong*/ + if(lParam != -1) sel.cpMin = SendMessage(hwnd, EM_CHARFROMPOS, 0, (LPARAM)&pt); /*doc is wrong*/ sel.cpMax = sel.cpMin; SendMessage(hwnd, EM_EXSETSEL, 0, (LPARAM)&sel); }