# HG changeset patch # User John Bailey # Date 1236459923 0 # Node ID c0115655a94e6e0b0fa333bd93f4b75995f98146 # Parent 7ace7bf0bfad449c7f6c16cf618186cee1785ab3 I have no idea how we've gone nearly 16 months with no one noticing that the SSL FAQ button resiak added to the mini dialog for no SSL support didn't actually appear. Instead of just making that button visible, I decided to change to using mini dialog API to add the button without the URL. diff -r 7ace7bf0bfad -r c0115655a94e pidgin/gtkblist.c --- a/pidgin/gtkblist.c Sat Mar 07 07:32:51 2009 +0000 +++ b/pidgin/gtkblist.c Sat Mar 07 21:05:23 2009 +0000 @@ -4838,8 +4838,9 @@ #define SSL_FAQ_URI "http://d.pidgin.im/wiki/FAQssl" static void -ssl_faq_clicked_cb(GtkButton *button, - PurpleAccount *account) +ssl_faq_clicked_cb(PidginMiniDialog *mini_dialog, + GtkButton *button, + gpointer ignored) { purple_notify_uri(NULL, SSL_FAQ_URI); } @@ -4872,25 +4873,9 @@ g_object_set_data(G_OBJECT(mini_dialog), OBJECT_DATA_KEY_ACCOUNT, account); - if(err->type == PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT) { - GtkWidget *faq_button = gtk_button_new(); - GtkWidget *faq_label = gtk_label_new(NULL); - gtk_label_set_markup(GTK_LABEL(faq_label), - "" SSL_FAQ_URI ""); -#if GTK_CHECK_VERSION(2,6,0) - g_object_set(G_OBJECT(faq_label), "ellipsize", - PANGO_ELLIPSIZE_MIDDLE, NULL); -#endif - gtk_container_add(GTK_CONTAINER(faq_button), faq_label); - gtk_button_set_relief(GTK_BUTTON(faq_button), GTK_RELIEF_NONE); - - g_signal_connect(faq_button, "clicked", - (GCallback)ssl_faq_clicked_cb, account); - - gtk_box_pack_start(PIDGIN_MINI_DIALOG(mini_dialog)->contents, - faq_button, FALSE, FALSE, 0); - } + if(err->type == PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT) + pidgin_mini_dialog_add_button(PIDGIN_MINI_DIALOG(mini_dialog), + _("SSL FAQs"), ssl_faq_clicked_cb, NULL); g_signal_connect_after(mini_dialog, "destroy", (GCallback)generic_error_destroy_cb,