From: Matthew Barnes Date: Fri, 10 Sep 2010 23:58:21 +0000 (-0400) Subject: Work around deprecation of gtk_dialog_set_has_separator() X-Git-Tag: upstream/3.7.4~2610 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4e6187e7df5649219909560634ce1786d2bf9df2;p=platform%2Fupstream%2Fevolution-data-server.git Work around deprecation of gtk_dialog_set_has_separator() Unfortunately the default value for this property is TRUE (bzzt, WRONG!) so we can't just remove the function outright until we require GTK+ 2.22. It was deprecated in GTK+ 2.21.8. --- diff --git a/libedataserverui/e-name-selector-dialog.c b/libedataserverui/e-name-selector-dialog.c index c3a58d7..6cf5d63 100644 --- a/libedataserverui/e-name-selector-dialog.c +++ b/libedataserverui/e-name-selector-dialog.c @@ -314,7 +314,9 @@ e_name_selector_dialog_init (ENameSelectorDialog *name_selector_dialog) gtk_window_set_modal (GTK_WINDOW (name_selector_dialog), TRUE); gtk_window_set_default_size (GTK_WINDOW (name_selector_dialog), 700, -1); gtk_window_set_resizable (GTK_WINDOW (name_selector_dialog), TRUE); +#if !GTK_CHECK_VERSION(2,21,8) gtk_dialog_set_has_separator (GTK_DIALOG (name_selector_dialog), FALSE); +#endif gtk_container_set_border_width (GTK_CONTAINER (name_selector_dialog), 4); gtk_window_set_title (GTK_WINDOW (name_selector_dialog), _("Select Contacts from Address Book")); gtk_widget_grab_focus (widget); diff --git a/libedataserverui/e-passwords.c b/libedataserverui/e-passwords.c index 9d3f232..85f7158 100644 --- a/libedataserverui/e-passwords.c +++ b/libedataserverui/e-passwords.c @@ -1143,7 +1143,9 @@ ep_ask_password (EPassMsg *msg) GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OK, GTK_RESPONSE_OK, NULL); +#if !GTK_CHECK_VERSION(2,21,8) gtk_dialog_set_has_separator (GTK_DIALOG (widget), FALSE); +#endif gtk_dialog_set_default_response ( GTK_DIALOG (widget), GTK_RESPONSE_OK); gtk_window_set_resizable (GTK_WINDOW (widget), FALSE); diff --git a/libedataserverui/e-source-selector-dialog.c b/libedataserverui/e-source-selector-dialog.c index 27fba4a..684beaf 100644 --- a/libedataserverui/e-source-selector-dialog.c +++ b/libedataserverui/e-source-selector-dialog.c @@ -99,7 +99,9 @@ e_source_selector_dialog_init (ESourceSelectorDialog *dialog) /* prepare the dialog */ gtk_window_set_title (GTK_WINDOW (dialog), _("Select destination")); gtk_window_set_default_size (GTK_WINDOW (dialog), 320, 240); +#if !GTK_CHECK_VERSION(2,21,8) gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE); +#endif gtk_widget_ensure_style (GTK_WIDGET (dialog)); gtk_container_set_border_width (GTK_CONTAINER (content_area), 0); gtk_container_set_border_width (GTK_CONTAINER (action_area), 12);