GNOME Bugzilla – Bug 526149
GtkCellRendererAccel editing conflicts with mnemonics
Last modified: 2009-08-23 07:01:38 UTC
Steps to repro: 0) Put a checkbox with mnemonic "A" in a window 1) Put a treeview with a GtkCellRendererAccel in the same window 1) Click to edit an accel 2) Press Alt-A Actual results: The checkbox gets focus and is toggled; the treeview/cell renderer loses focus but is not reset, nor changes to Alt-A. Expected results: Editing the accel to Alt-A succeeds.
Created attachment 108606 [details] [review] [PATCH] Add checkbox as testcase for bug #526149. tests/testaccel.c | 12 ++++++++++-- 1 files changed, 10 insertions(+), 2 deletions(-)
*** Bug 140378 has been marked as a duplicate of this bug. ***
*** Bug 492761 has been marked as a duplicate of this bug. ***
Problem here seems to be that GtkWindow's default key-press-event handler gets called before the accel cell's. Which is weird because key-press-event is a RUN_LAST signal so you would expect the accel cell's signal handler to be run first. Need to investigate this further; should be nailed soon ;)
This is still reproducible using gtk+ git master. (In reply to comment #4) > Need to investigate this further; should be nailed soon ;) Did you get a chance to look into this?
Fixed now: commit 6320b12e8c63bd13ca33c5d206d9d2f322f8b21d Author: Kristian Rietveld <kris@gtk.org> Date: Sun Aug 23 08:59:34 2009 +0200 Bug 526149 - GtkCellRendererAccel editing conflicts with mnemonics GtkCellRendererAccel also needs to acquire the GTK+ grab in addition to a GDK keyboard grab. With the GDK keyboard grab, KeyPress and KeyRelease events are delivered as usual, although we only want to receive them for our grab widget.