some cleanups, fixed mnemonic_widget handling, added PROP_MNEMONIC_WIDGET.

Thu Mar 22 13:01:44 2001  Tim Janik  <timj@gtk.org>

        * gtk/gtklabel.[hc]: some cleanups, fixed mnemonic_widget handling,
        added PROP_MNEMONIC_WIDGET.

        * gtk/gtkwindow.c (gtk_window_activate_mnemonic):
        (gtk_window_remove_mnemonic):
        (gtk_window_add_mnemonic): fixed assertions.
        (gtk_window_activate_mnemonic): constrain modifier checks to those
        permitted by gtk_accelerator_get_default_mod_mask().
        got rid of gtk_window_get_default_accel_group().

        * gtk/gtkwidget.c (gtk_widget_real_activate_mnemonic): handle non
        activatable widgets either by focussing or a warning.
        added a signal accumulator to ::activate_mnemonic which stops the
        emission once a handler returned TRUE.
This commit is contained in:
Tim Janik
2001-03-22 13:44:00 +00:00
committed by Tim Janik
parent 6e58fd1ee3
commit c2c98d9e12
25 changed files with 497 additions and 349 deletions

View File

@ -3638,18 +3638,17 @@ gtk_notebook_activate_mnemonic_switch_page (GtkWidget *child,
gpointer data)
{
GtkNotebook *notebook = GTK_NOTEBOOK (data);
GtkNotebookPage *page;
GList *list;
list = g_list_find_custom (notebook->children, child,
gtk_notebook_page_compare_tab);
if (!list)
return TRUE;
if (list)
{
GtkNotebookPage *page = list->data;
gtk_notebook_switch_page (notebook, page, -1);
}
page = list->data;
gtk_notebook_switch_page (notebook, page, -1);
return TRUE;
}