]> git.meshlink.io Git - catta/commitdiff
Compile with -DGSEAL_ENABLE. Fixes http://avahi.org/ticket/305
authorAndre Klapper <a9016009@gmx.de>
Sun, 11 Apr 2010 11:51:11 +0000 (13:51 +0200)
committerLennart Poettering <lennart@poettering.net>
Mon, 19 Apr 2010 17:33:17 +0000 (19:33 +0200)
avahi-ui/avahi-ui.c
configure.ac

index bd2b3cc1a9fe460049dc77dbf4a0b8f550803e5c..2e8f3278356ff56025cff26a7626c3023535fd66 100644 (file)
@@ -131,16 +131,16 @@ static void aui_service_dialog_get_property(GObject *object, guint prop_id, GVal
 static int get_default_response(GtkDialog *dlg) {
     gint ret = GTK_RESPONSE_NONE;
 
-    if (GTK_WINDOW(dlg)->default_widget)
+    if (gtk_window_get_default_widget(GTK_WINDOW(dlg)))
         /* Use the response of the default widget, if possible */
-        ret = gtk_dialog_get_response_for_widget(dlg, GTK_WINDOW(dlg)->default_widget);
+        ret = gtk_dialog_get_response_for_widget(dlg, gtk_window_get_default_widget(GTK_WINDOW(dlg)));
 
     if (ret == GTK_RESPONSE_NONE) {
         /* Fall back to finding the first positive response */
         GList *children, *t;
         gint bad = GTK_RESPONSE_NONE;
 
-        t = children = gtk_container_get_children(GTK_CONTAINER(dlg->action_area));
+        t = children = gtk_container_get_children(GTK_CONTAINER(gtk_dialog_get_action_area(dlg)));
 
         while (t) {
             GtkWidget *child = t->data;
@@ -890,7 +890,7 @@ static void response_callback(GtkDialog *dialog, gint response, gpointer user_da
 
         gtk_widget_set_sensitive(GTK_WIDGET(dialog), FALSE);
         cursor = gdk_cursor_new(GDK_WATCH);
-        gdk_window_set_cursor(GTK_WIDGET(dialog)->window, cursor);
+        gdk_window_set_cursor(gtk_widget_get_window(GTK_WIDGET(dialog)), cursor);
         gdk_cursor_unref(cursor);
 
         if (!(d->priv->resolver = avahi_service_resolver_new(
@@ -992,7 +992,7 @@ static void domain_button_clicked(GtkButton *button G_GNUC_UNUSED, gpointer user
 
     vbox = gtk_vbox_new(FALSE, 8);
     gtk_container_set_border_width(GTK_CONTAINER(vbox), 8);
-    gtk_box_pack_start(GTK_BOX(GTK_DIALOG(p->domain_dialog)->vbox), vbox, TRUE, TRUE, 0);
+    gtk_box_pack_start(GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(p->domain_dialog))), vbox, TRUE, TRUE, 0);
 
     p->domain_entry = gtk_entry_new();
     gtk_entry_set_max_length(GTK_ENTRY(p->domain_entry), AVAHI_DOMAIN_NAME_MAX);
@@ -1114,7 +1114,7 @@ static void aui_service_dialog_init(AuiServiceDialog *d) {
 
     vbox = gtk_vbox_new(FALSE, 8);
     gtk_container_set_border_width(GTK_CONTAINER(vbox), 8);
-    gtk_box_pack_start(GTK_BOX(GTK_DIALOG(d)->vbox), vbox, TRUE, TRUE, 0);
+    gtk_box_pack_start(GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(d))), vbox, TRUE, TRUE, 0);
 
     p->domain_label = gtk_label_new(_("Initializing..."));
     gtk_label_set_ellipsize(GTK_LABEL(p->domain_label), TRUE);
@@ -1165,8 +1165,8 @@ static void aui_service_dialog_init(AuiServiceDialog *d) {
     p->domain_button = gtk_button_new_with_mnemonic(_("_Domain..."));
     gtk_button_set_image(GTK_BUTTON(p->domain_button), gtk_image_new_from_stock(GTK_STOCK_NETWORK, GTK_ICON_SIZE_BUTTON));
     g_signal_connect(p->domain_button, "clicked", G_CALLBACK(domain_button_clicked), d);
-    gtk_box_pack_start(GTK_BOX(GTK_DIALOG(d)->action_area), p->domain_button, FALSE, TRUE, 0);
-    gtk_button_box_set_child_secondary(GTK_BUTTON_BOX(GTK_DIALOG(d)->action_area), p->domain_button, TRUE);
+    gtk_box_pack_start(GTK_BOX(gtk_dialog_get_action_area(GTK_DIALOG(d))), p->domain_button, FALSE, TRUE, 0);
+    gtk_button_box_set_child_secondary(GTK_BUTTON_BOX(gtk_dialog_get_action_area(GTK_DIALOG(d))), p->domain_button, TRUE);
     gtk_widget_show(p->domain_button);
 
     gtk_dialog_set_default_response(GTK_DIALOG(d), GTK_RESPONSE_ACCEPT);
index 1947b8ef859ca8f206812a203102d292b65b724e..4e527bc53205ce6665fcbf38fbfa0ef69f311d1c 100644 (file)
@@ -531,7 +531,7 @@ AC_ARG_ENABLE(gtk,
 
 if test "x$HAVE_GTK" = "xyes" ; then
         # Check for GTK 2.0
-        PKG_CHECK_MODULES(GTK20, [ gtk+-2.0 >= 2.12.0 ])
+        PKG_CHECK_MODULES(GTK20, [ gtk+-2.0 >= 2.14.0 ])
         AC_SUBST(GTK20_CFLAGS)
         AC_SUBST(GTK20_LIBS)
 fi