diff options
| -rw-r--r-- | win32/ScintillaWin.cxx | 21 | 
1 files changed, 11 insertions, 10 deletions
diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx index 39ac139af..73e8736fd 100644 --- a/win32/ScintillaWin.cxx +++ b/win32/ScintillaWin.cxx @@ -886,16 +886,17 @@ sptr_t ScintillaWin::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam  				} else {  					// Display regular (drag) cursor over selection  					POINT pt; -					::GetCursorPos(&pt); -					::ScreenToClient(MainHWND(), &pt); -					if (PointInSelMargin(Point(pt.x, pt.y))) { -						DisplayCursor(GetMarginCursor(Point(pt.x, pt.y))); -					} else if (PointInSelection(Point(pt.x, pt.y)) && !SelectionEmpty()) { -						DisplayCursor(Window::cursorArrow); -					} else if (PointIsHotspot(Point(pt.x, pt.y))) { -						DisplayCursor(Window::cursorHand); -					} else { -						DisplayCursor(Window::cursorText); +					if (0 != ::GetCursorPos(&pt)) { +						::ScreenToClient(MainHWND(), &pt); +						if (PointInSelMargin(Point(pt.x, pt.y))) { +							DisplayCursor(GetMarginCursor(Point(pt.x, pt.y))); +						} else if (PointInSelection(Point(pt.x, pt.y)) && !SelectionEmpty()) { +							DisplayCursor(Window::cursorArrow); +						} else if (PointIsHotspot(Point(pt.x, pt.y))) { +							DisplayCursor(Window::cursorHand); +						} else { +							DisplayCursor(Window::cursorText); +						}  					}  				}  				return TRUE;  | 
