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 316125 - When a GtkButton is sensitized, it should check the cursor position
When a GtkButton is sensitized, it should check the cursor position
Status: RESOLVED DUPLICATE of bug 56070
Product: gtk+
Classification: Platform
Component: Widget: Other
2.8.x
Other Linux
: Normal normal
: Medium fix
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2005-09-12 21:13 UTC by Torsten Schoenfeld
Modified: 2006-12-26 05:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Prelighting desensitized buttons (1.49 KB, patch)
2005-09-12 21:15 UTC, Torsten Schoenfeld
needs-work Details | Review

Description Torsten Schoenfeld 2005-09-12 21:13:42 UTC
Currently when an insensitive GtkButton is sensitized while the cursor hovers
above it, the button doesn't change to the prelight state and can't be used
without moving the cursor out of the button and back in.

Here's a patch (against the gtk-2-8 branch) that attempts to rectify this.  It
does work in my humble testing efforts.  I'm not familar with the GtkButton
internals though, so I'm not sure the patch's correct.
Comment 1 Torsten Schoenfeld 2005-09-12 21:15:52 UTC
Created attachment 52146 [details] [review]
Prelighting desensitized buttons
Comment 2 Tim Janik 2005-09-13 20:21:01 UTC
this is a symptom of the more general problem that gtk doesn't synthesize
enter/leave events upon changing the sensitivity (or global grab) state of a
widget the way X does when windows are covered/uncovered by other windows.

it should prolly be discussed whether a more generic solution to this problem is
worth implementing for gtk. if that does not turn out to be the case, patching
this behaviour up only for buttons may still make sense as this is one of the
cases where it shows up most.

however, the attached patch doesn't fully solve the problem, it can cause
buttons to enter prelight state, eventhough a global gtk grab is currently in
effect. similar related problems may appear due to missing enter/leave events,
like tooltips not showing up. 
the complexity involved with grabs and enter/leave/crossing events when patching
up state behaviour in individual widgets is part of the reason why this could
make sense to be handled generically in gtk.
Comment 3 Billy Biggs 2005-10-25 21:23:40 UTC
This should probably be marked as a duplicate of bug 56070.
Comment 4 Matthias Clasen 2006-12-26 05:05:55 UTC

*** This bug has been marked as a duplicate of 56070 ***