After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 556006 - Leave & enter notify events are generated on button presses
Leave & enter notify events are generated on button presses
Status: RESOLVED OBSOLETE
Product: gtk+
Classification: Platform
Component: Widget: Other
unspecified
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2008-10-12 11:39 UTC by Damon Chaplin
Modified: 2018-05-02 14:35 UTC
See Also:
GNOME target: ---
GNOME version: 2.19/2.20


Attachments
test case (3.08 KB, text/plain)
2008-10-12 11:41 UTC, Damon Chaplin
Details
testcase (1.53 KB, text/x-csrc)
2011-08-11 11:14 UTC, Valentín Barros
Details

Description Damon Chaplin 2008-10-12 11:39:16 UTC
Please describe the problem:
When I click on a widget (e.g. a drawing area) it receives leave and enter
notify events before the button press event. (Happens with svn and 2.12.8)

This may be related to pointer grabs - I think X will generate leave and enter
notify events if the grab window is different from the current window. But if
they are the same I don't think it should.

I'll attach a test case.

Steps to reproduce:
1. 
2. 
3. 


Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Damon Chaplin 2008-10-12 11:41:07 UTC
Created attachment 120430 [details]
test case
Comment 2 Valentín Barros 2011-08-11 11:13:09 UTC
Hi.

I've found the same wrong behavior. At first I've thought that it could be a Vala problem [1], but now I discard it since I can get the same behavior from a C program --like you Damon, but I haven't seen this bug report before.

I attach my own test case. 

Note a couple of things:
    * I only see errors with enter_notify_event --I see both enter & leave only in Ubuntu Natty with Unity and a transient window present, but it seems to be an Unity problem that furthermore isn't present in Ubuntu Oneiric.
    * If you only add GDK_LEAVE_NOTIFY_MASK | GDK_ENTER_NOTIFY_MASK to a GtkDrawingArea you can see the problem, but it doesn't appear if you also add GDK_BUTTON_PRESS_MASK.

I can see the reported problem in the following systems:

    * Linux Mint 10 with Gnome 2.32.0 (of course without Unity)
    * Ubuntu Natty with Gnome 2.32.1 (without Unity; with it I see the problem commented above and only if the program has a transient window --more info in [1])
    * Ubuntu Oneiric Alpha 3 with Gnome 3.1.4 (with Unity but without Compiz)

Cheers!

[1] https://bugzilla.gnome.org/show_bug.cgi?id=656288
Comment 3 Valentín Barros 2011-08-11 11:14:44 UTC
Created attachment 193631 [details]
testcase
Comment 4 GNOME Infrastructure Team 2018-05-02 14:35:12 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gtk/issues/301.