-#include <config.h>
+/* testmerge.c
+ * Copyright (C) 2003 James Henstridge
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#include "config.h"
#include <stdio.h>
#include <string.h>
gchar *dump;
dump = gtk_ui_manager_get_ui (merge);
- g_message (dump);
+ g_message ("%s", dump);
g_free (dump);
}
toggle_dynamic (GtkWidget *button,
GtkUIManager *merge)
{
- g_timeout_add (2000, (GSourceFunc)delayed_toggle_dynamic, merge);
+ gdk_threads_add_timeout (2000, (GSourceFunc)delayed_toggle_dynamic, merge);
}
static void
"could not merge %s: %s", merge_ids[mergenum].filename,
err->message);
- g_signal_connect (dialog, "response", G_CALLBACK (gtk_object_destroy), NULL);
+ g_signal_connect (dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL);
gtk_widget_show (dialog);
g_clear_error (&err);
gtk_list_store_append (store, &iter);
gtk_list_store_set (store, &iter, 0, l->data, -1);
}
+
+ g_list_free (actions);
}
tree_view = gtk_tree_view_new_with_model (GTK_TREE_MODEL (store));
gtk_table_attach (GTK_TABLE (table), frame, 0,2, 1,2,
GTK_FILL|GTK_EXPAND, GTK_FILL, 0, 0);
- menu_box = gtk_vbox_new (FALSE, 0);
+ menu_box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_set_border_width (GTK_CONTAINER (menu_box), 2);
gtk_container_add (GTK_CONTAINER (frame), menu_box);
button = gtk_button_new ();
gtk_box_pack_end (GTK_BOX (menu_box), button, FALSE, FALSE, 0);
- gtk_action_connect_proxy (gtk_action_group_get_action (action_group, "AboutAction"),
- button);
+ gtk_activatable_set_related_action (GTK_ACTIVATABLE (button),
+ gtk_action_group_get_action (action_group, "AboutAction"));
+
gtk_widget_show (button);
button = gtk_check_button_new ();
gtk_box_pack_end (GTK_BOX (menu_box), button, FALSE, FALSE, 0);
- gtk_action_connect_proxy (gtk_action_group_get_action (action_group, "BoldAction"),
- button);
+ gtk_activatable_set_related_action (GTK_ACTIVATABLE (button),
+ gtk_action_group_get_action (action_group, "BoldAction"));
gtk_widget_show (button);
merge = gtk_ui_manager_new ();
gtk_table_attach (GTK_TABLE (table), frame, 0,1, 0,1,
GTK_FILL, GTK_FILL|GTK_EXPAND, 0, 0);
- vbox = gtk_vbox_new (FALSE, 2);
+ vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 2);
gtk_container_set_border_width (GTK_CONTAINER (vbox), 2);
gtk_container_add (GTK_CONTAINER (frame), vbox);