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 622260 - GtkRadioMenuItem does not emit 'notify::active' on activate
GtkRadioMenuItem does not emit 'notify::active' on activate
Status: RESOLVED OBSOLETE
Product: gtk+
Classification: Platform
Component: Widget: GtkMenu
2.90.x
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2010-06-21 06:02 UTC by Richard Procter
Modified: 2018-02-10 03:36 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Refactoring of gtk_radio_menu_item_activate() (3.50 KB, patch)
2010-06-21 06:02 UTC, Richard Procter
none Details | Review
Fix of refactored gtk_radio_menu_item_activate() (576 bytes, patch)
2010-06-21 06:05 UTC, Richard Procter
none Details | Review
Testcase (1.35 KB, application/octet-stream)
2010-06-21 06:06 UTC, Richard Procter
  Details

Description Richard Procter 2010-06-21 06:02:54 UTC
Created attachment 164198 [details] [review]
Refactoring of gtk_radio_menu_item_activate()

As GtkRadioMenuItem is a subclass of GtkCheckMenuItem it should emit a notify::active signal when gtk_menu_item_activate() is invoked on it.  

Here is a fix, split into two patches: the first refactors gtk_radio_menu_item_activate() and the second adds the g_object_notify() call. 

Note: the fix modifes the original code slightly by making the gtk_widget_queue_draw call conditional on whether the active state was in fact changed.  



best regards, 
Richard.
Comment 1 Richard Procter 2010-06-21 06:05:27 UTC
Created attachment 164199 [details] [review]
Fix of refactored gtk_radio_menu_item_activate()
Comment 2 Richard Procter 2010-06-21 06:06:57 UTC
Created attachment 164200 [details]
Testcase 

Compiled with gcc $ testcase.c `pkg-config --cflags --libs gtk+-2.0` -o testcase
Comment 3 Matthias Clasen 2018-02-10 03:36:50 UTC
We're moving to gitlab! As part of this move, we are closing bugs that haven't seen activity in more than 5 years. If this issue is still imporant to you and
still relevant with GTK+ 3.22 or master, please consider creating a gitlab issue
for it.