summaryrefslogtreecommitdiffstats
path: root/generic/tkCanvas.c
diff options
context:
space:
mode:
authordgp <dgp@noemail.net>2008-04-17 14:48:21 (GMT)
committerdgp <dgp@noemail.net>2008-04-17 14:48:21 (GMT)
commitf750317c14c4833671dd455f536ddafa9dc0223e (patch)
treefa544f2f96397853a3db1525b7b051b3bb340e12 /generic/tkCanvas.c
parentfb65f92430e6db7ed300798b11fae1971c104ded (diff)
downloadtk-f750317c14c4833671dd455f536ddafa9dc0223e.zip
tk-f750317c14c4833671dd455f536ddafa9dc0223e.tar.gz
tk-f750317c14c4833671dd455f536ddafa9dc0223e.tar.bz2
* generic/tkCanvas.c: Fix logic that determines when canvas item
<Enter> event should fire. Thanks to Sebastian Wangnick. [Bug 1327482] FossilOrigin-Name: 34f1ba78d705912888096725f5fd827691dab68f
Diffstat (limited to 'generic/tkCanvas.c')
-rw-r--r--generic/tkCanvas.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/generic/tkCanvas.c b/generic/tkCanvas.c
index 9d4dd05..79630db 100644
--- a/generic/tkCanvas.c
+++ b/generic/tkCanvas.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkCanvas.c,v 1.21.2.4 2007/04/29 02:24:01 das Exp $
+ * RCS: @(#) $Id: tkCanvas.c,v 1.21.2.5 2008/04/17 14:48:23 dgp Exp $
*/
/* #define USE_OLD_TAG_SEARCH 1 */
@@ -4663,9 +4663,6 @@ PickCurrentItem(canvasPtr, eventPtr)
buttonDown = canvasPtr->state
& (Button1Mask|Button2Mask|Button3Mask|Button4Mask|Button5Mask);
- if (!buttonDown) {
- canvasPtr->flags &= ~LEFT_GRABBED_ITEM;
- }
/*
* Save information about this event in the canvas. The event in
@@ -4739,6 +4736,10 @@ PickCurrentItem(canvasPtr, eventPtr)
return;
}
+ if (!buttonDown) {
+ canvasPtr->flags &= ~LEFT_GRABBED_ITEM;
+ }
+
/*
* Simulate a LeaveNotify event on the previous current item and
* an EnterNotify event on the new current item. Remove the "current"