Skip to content
  • Carlos Garnacho's avatar
    GtkMenuButton: explicitly protect against recursion · 65f7fb04
    Carlos Garnacho authored and Matthias Clasen's avatar Matthias Clasen committed
    The visibility toggling happening on ::click() relied implicitly
    on the popover animation, but breaks on disabled animations. The
    recursion happening within gtk_toggle_button_set_active() (which
    triggers ::clicked when changing state) makes this vfunc to run
    again, inverting the visibility of the popover in result.
    
    Fix this by explicitly checking about recursion, we want the
    button to be toggled to the right state, but we don't want the
    callback running again.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=752577
    65f7fb04