• Emmanuele Bassi's avatar
    link-button: Add ::activate-link signal · 17ffcb0c
    Emmanuele Bassi authored
    We cannot use the GtkButton::clicked signal to override the default
    behavior of GtkLinkButton (i.e. call gtk_show_uri()), because
    GtkButton::clicked is registered as a RUN_FIRST signal, which obviously
    prevents any other signal handler connected to it to stop the
    propagation before the class handler has a chance to run.
    For this reason we can add a GtkLinkButton::activate-link signal, which
    will be emitted by the default GtkButton::clicked signal handler; the
    ::activate-link signal has a boolean return value, which allows simpler
    code for stopping the propagation to the next signal handler.
gtklinkbutton.c 22 KB