summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2020-07-06 21:18:01 (GMT)
committerfvogel <fvogelnew1@free.fr>2020-07-06 21:18:01 (GMT)
commitdb1b8a5882c70d2016d8f24c02bc8f70fa5eb155 (patch)
tree8d085da06a79462d43f0b1deaef12dea3b571a6b /generic
parenta3aa1937eb168fe1779bfba8ce88b3ef74315630 (diff)
parent1d82b1078322a72b9551982472e2e13f7a470ffd (diff)
downloadtk-db1b8a5882c70d2016d8f24c02bc8f70fa5eb155.zip
tk-db1b8a5882c70d2016d8f24c02bc8f70fa5eb155.tar.gz
tk-db1b8a5882c70d2016d8f24c02bc8f70fa5eb155.tar.bz2
Fix [e3888d5820]: Grab on master prevents mouse pointer warp into slave widget. Mouse pointer warping happens at idle time, and the fix does not change this.
Diffstat (limited to 'generic')
-rw-r--r--generic/tkBind.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/generic/tkBind.c b/generic/tkBind.c
index fbc976b..eacdf56 100644
--- a/generic/tkBind.c
+++ b/generic/tkBind.c
@@ -4388,17 +4388,6 @@ HandleEventGenerate(
}
/*
- * Now we have constructed the event, inject it into the event handling
- * code.
- */
-
- if (synch) {
- Tk_HandleEvent(&event.general);
- } else {
- Tk_QueueWindowEvent(&event.general, pos);
- }
-
- /*
* We only allow warping if the window is mapped.
*/
@@ -4407,11 +4396,6 @@ HandleEventGenerate(
Tk_Window warpWindow = Tk_IdToWindow(dispPtr->display, event.general.xmotion.window);
- if (!(dispPtr->flags & TK_DISPLAY_IN_WARP)) {
- Tcl_DoWhenIdle(DoWarp, dispPtr);
- dispPtr->flags |= TK_DISPLAY_IN_WARP;
- }
-
if (warpWindow != dispPtr->warpWindow) {
if (warpWindow) {
Tcl_Preserve(warpWindow);
@@ -4424,6 +4408,22 @@ HandleEventGenerate(
dispPtr->warpMainwin = mainWin;
dispPtr->warpX = event.general.xmotion.x;
dispPtr->warpY = event.general.xmotion.y;
+
+ if (!(dispPtr->flags & TK_DISPLAY_IN_WARP)) {
+ Tcl_DoWhenIdle(DoWarp, dispPtr);
+ dispPtr->flags |= TK_DISPLAY_IN_WARP;
+ }
+ }
+
+ /*
+ * Now we have constructed the event, inject it into the event handling
+ * code.
+ */
+
+ if (synch) {
+ Tk_HandleEvent(&event.general);
+ } else {
+ Tk_QueueWindowEvent(&event.general, pos);
}
}