From 2afe25753afb3279629a1e63c9340a4738c9bfa9 Mon Sep 17 00:00:00 2001 From: Danielle Madeley Date: Fri, 18 Dec 2009 17:28:42 +1100 Subject: [EmpathyContactSelectorDialog] switch from table_contents to VBox This makes it more flexible to add other contents to the dialog. --- libempathy-gtk/empathy-contact-selector-dialog.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'libempathy-gtk/empathy-contact-selector-dialog.c') diff --git a/libempathy-gtk/empathy-contact-selector-dialog.c b/libempathy-gtk/empathy-contact-selector-dialog.c index 8f1ec149f..77eb7971f 100644 --- a/libempathy-gtk/empathy-contact-selector-dialog.c +++ b/libempathy-gtk/empathy-contact-selector-dialog.c @@ -272,6 +272,9 @@ empathy_contact_selector_dialog_init (EmpathyContactSelectorDialog *dialog) GtkEntryCompletion *completion; GtkListStore *model; GtkWidget *content_area; + GtkWidget *table_contact; + + dialog->vbox = gtk_vbox_new (FALSE, 3); /* create a contact manager */ priv->contact_manager = empathy_contact_manager_dup_singleton (); @@ -279,7 +282,7 @@ empathy_contact_selector_dialog_init (EmpathyContactSelectorDialog *dialog) filename = empathy_file_lookup ("empathy-contact-selector-dialog.ui", "libempathy-gtk"); gui = empathy_builder_get_file (filename, - "table_contact", &dialog->table_contact, + "table_contact", &table_contact, "account_chooser_label", &priv->account_chooser_label, "entry_id", &priv->entry_id, NULL); @@ -290,7 +293,9 @@ empathy_contact_selector_dialog_init (EmpathyContactSelectorDialog *dialog) NULL); content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); - gtk_container_add (GTK_CONTAINER (content_area), dialog->table_contact); + gtk_container_add (GTK_CONTAINER (content_area), dialog->vbox); + gtk_box_pack_start (GTK_BOX (dialog->vbox), table_contact, TRUE, TRUE, 0); + gtk_widget_show (dialog->vbox); gtk_dialog_add_button (GTK_DIALOG (dialog), GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL); @@ -330,7 +335,7 @@ empathy_contact_selector_dialog_init (EmpathyContactSelectorDialog *dialog) /* Create account chooser */ priv->account_chooser = empathy_account_chooser_new (); - gtk_table_attach_defaults (GTK_TABLE (dialog->table_contact), + gtk_table_attach_defaults (GTK_TABLE (table_contact), priv->account_chooser, 1, 2, 0, 1); empathy_account_chooser_set_filter ( -- cgit v1.2.3