diff options
author | nijtmans@users.sourceforge.net <jan.nijtmans> | 2012-04-20 12:50:11 (GMT) |
---|---|---|
committer | nijtmans@users.sourceforge.net <jan.nijtmans> | 2012-04-20 12:50:11 (GMT) |
commit | ca412b689588f06ab04e78342524767e8e9e686c (patch) | |
tree | ac02899a473761587e13b2906482b07f4bb0bb66 /generic/tkFocus.c | |
parent | eec8ff3ad044a1aaf408b16b3b8594e036989c41 (diff) | |
parent | a2ff6197200d4070abc990f1aad8f468f35c0f99 (diff) | |
download | tk-ca412b689588f06ab04e78342524767e8e9e686c.zip tk-ca412b689588f06ab04e78342524767e8e9e686c.tar.gz tk-ca412b689588f06ab04e78342524767e8e9e686c.tar.bz2 |
fix (hopefully) menu posting in the same way as window placement
Diffstat (limited to 'generic/tkFocus.c')
-rw-r--r-- | generic/tkFocus.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/generic/tkFocus.c b/generic/tkFocus.c index aad1305..93e1617 100644 --- a/generic/tkFocus.c +++ b/generic/tkFocus.c @@ -737,7 +737,7 @@ TkFocusKeyEvent(winPtr, eventPtr) { DisplayFocusInfo *displayFocusPtr; TkWindow *focusWinPtr; - int focusX, focusY, vRootX, vRootY, vRootWidth, vRootHeight; + int focusX, focusY; displayFocusPtr = FindDisplayFocusInfo(winPtr->mainPtr, winPtr->dispPtr); focusWinPtr = displayFocusPtr->focusWinPtr; @@ -770,11 +770,9 @@ TkFocusKeyEvent(winPtr, eventPtr) eventPtr->xkey.x = -1; eventPtr->xkey.y = -1; } else { - Tk_GetVRootGeometry((Tk_Window) focusWinPtr, &vRootX, &vRootY, - &vRootWidth, &vRootHeight); Tk_GetRootCoords((Tk_Window) focusWinPtr, &focusX, &focusY); - eventPtr->xkey.x = eventPtr->xkey.x_root - vRootX - focusX; - eventPtr->xkey.y = eventPtr->xkey.y_root - vRootY - focusY; + eventPtr->xkey.x = eventPtr->xkey.x_root - focusX; + eventPtr->xkey.y = eventPtr->xkey.y_root - focusY; } eventPtr->xkey.window = focusWinPtr->window; return focusWinPtr; |