From 94796510222de972274beb287fa2aaa581dd4a7a Mon Sep 17 00:00:00 2001 From: marc_culler Date: Sat, 16 May 2020 14:20:06 +0000 Subject: Remove code from TkpWarpPointer which was only needed to construct the NSEvent that is no longer being constructed. --- macosx/tkMacOSXMouseEvent.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/macosx/tkMacOSXMouseEvent.c b/macosx/tkMacOSXMouseEvent.c index 9a4dc46..e8296e2 100644 --- a/macosx/tkMacOSXMouseEvent.c +++ b/macosx/tkMacOSXMouseEvent.c @@ -641,25 +641,15 @@ TkpWarpPointer( TkDisplay *dispPtr) { CGPoint pt; - NSPoint loc; - int wNum; if (dispPtr->warpWindow) { int x, y; - TkWindow *winPtr = (TkWindow *) dispPtr->warpWindow; - TkWindow *topPtr = winPtr->privatePtr->toplevel->winPtr; - NSWindow *w = TkMacOSXDrawableWindow(winPtr->window); - wNum = [w windowNumber]; Tk_GetRootCoords(dispPtr->warpWindow, &x, &y); pt.x = x + dispPtr->warpX; pt.y = y + dispPtr->warpY; - loc.x = dispPtr->warpX; - loc.y = Tk_Height(topPtr) - dispPtr->warpY; } else { - wNum = 0; - pt.x = loc.x = dispPtr->warpX; + pt.x = dispPtr->warpX; pt.y = dispPtr->warpY; - loc.y = TkMacOSXZeroScreenHeight() - pt.y; } CGWarpMouseCursorPosition(pt); -- cgit v0.12