diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2010-01-31 03:03:19 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2010-04-08 23:05:26 +0800 |
commit | 72797decc12602b181f69dba7c54df7a0d1b9326 (patch) | |
tree | ecd1314c92bc26b59647b351b2d47e446f4ed21d /plugins | |
parent | 3ba0b61f9f447b01c3a83bfb78ee33a45d413700 (diff) | |
download | gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.tar gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.tar.gz gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.tar.bz2 gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.tar.lz gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.tar.xz gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.tar.zst gsoc2013-evolution-72797decc12602b181f69dba7c54df7a0d1b9326.zip |
Giant leap towards GSEAL compliance.
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/attachment-reminder/attachment-reminder.c | 7 | ||||
-rw-r--r-- | plugins/backup-restore/backup.c | 20 | ||||
-rw-r--r-- | plugins/bbdb/bbdb.c | 6 | ||||
-rw-r--r-- | plugins/calendar-weather/calendar-weather.c | 6 | ||||
-rw-r--r-- | plugins/email-custom-header/email-custom-header.c | 10 | ||||
-rw-r--r-- | plugins/groupwise-features/junk-mail-settings.c | 10 | ||||
-rw-r--r-- | plugins/groupwise-features/mail-retract.c | 16 | ||||
-rw-r--r-- | plugins/groupwise-features/share-folder-common.c | 6 | ||||
-rw-r--r-- | plugins/groupwise-features/status-track.c | 4 | ||||
-rw-r--r-- | plugins/image-inline/image-inline.c | 4 | ||||
-rw-r--r-- | plugins/itip-formatter/itip-formatter.c | 6 | ||||
-rw-r--r-- | plugins/itip-formatter/itip-view.c | 4 | ||||
-rw-r--r-- | plugins/mail-notification/mail-notification.c | 5 | ||||
-rw-r--r-- | plugins/mark-all-read/mark-all-read.c | 5 | ||||
-rw-r--r-- | plugins/publish-calendar/url-editor-dialog.c | 8 | ||||
-rw-r--r-- | plugins/startup-wizard/startup-wizard.c | 23 |
16 files changed, 89 insertions, 51 deletions
diff --git a/plugins/attachment-reminder/attachment-reminder.c b/plugins/attachment-reminder/attachment-reminder.c index b74406bb47..983327df73 100644 --- a/plugins/attachment-reminder/attachment-reminder.c +++ b/plugins/attachment-reminder/attachment-reminder.c @@ -112,14 +112,17 @@ ask_for_missing_attachment (EPlugin *ep, GtkWindow *window) { GtkWidget *check = NULL; GtkDialog *dialog = NULL; + GtkWidget *content_area; gint response; - dialog = (GtkDialog*)e_alert_dialog_new_for_args(window, "org.gnome.evolution.plugins.attachment_reminder:attachment-reminder", NULL); + dialog = (GtkDialog*) e_alert_dialog_new_for_args ( + window, "org.gnome.evolution.plugins.attachment_reminder:attachment-reminder", NULL); /*Check buttons*/ check = gtk_check_button_new_with_mnemonic (_("_Do not show this message again.")); gtk_container_set_border_width((GtkContainer *)check, 12); - gtk_box_pack_start ((GtkBox *)dialog->vbox, check, TRUE, TRUE, 0); + content_area = gtk_dialog_get_content_area (dialog); + gtk_box_pack_start (GTK_BOX (content_area), check, TRUE, TRUE, 0); gtk_widget_show (check); response = gtk_dialog_run ((GtkDialog *) dialog); diff --git a/plugins/backup-restore/backup.c b/plugins/backup-restore/backup.c index 9f7e70c5b2..9304a135c1 100644 --- a/plugins/backup-restore/backup.c +++ b/plugins/backup-restore/backup.c @@ -443,6 +443,8 @@ main (gint argc, gchar **argv) if (gui_arg && !check_op) { GtkWidget *widget, *container; + GtkWidget *action_area; + GtkWidget *content_area; const gchar *txt, *txt2; gchar *str = NULL; gchar *markup; @@ -460,13 +462,16 @@ main (gint argc, gchar **argv) gtk_dialog_set_has_separator (GTK_DIALOG (progress_dialog), FALSE); gtk_container_set_border_width (GTK_CONTAINER (progress_dialog), 12); + action_area = gtk_dialog_get_action_area ( + GTK_DIALOG (progress_dialog)); + content_area = gtk_dialog_get_content_area ( + GTK_DIALOG (progress_dialog)); + /* Override GtkDialog defaults */ - widget = GTK_DIALOG (progress_dialog)->vbox; - gtk_box_set_spacing (GTK_BOX (widget), 12); - gtk_container_set_border_width (GTK_CONTAINER (widget), 0); - widget = GTK_DIALOG (progress_dialog)->action_area; - gtk_box_set_spacing (GTK_BOX (widget), 12); - gtk_container_set_border_width (GTK_CONTAINER (widget), 0); + gtk_box_set_spacing (GTK_BOX (content_area), 12); + gtk_container_set_border_width (GTK_CONTAINER (content_area), 0); + gtk_box_set_spacing (GTK_BOX (action_area), 12); + gtk_container_set_border_width (GTK_CONTAINER (action_area), 0); if (oper && file) str = g_strdup_printf(oper, file); @@ -476,7 +481,8 @@ main (gint argc, gchar **argv) gtk_table_set_row_spacings (GTK_TABLE (container), 12); gtk_widget_show (container); - gtk_box_pack_start (GTK_BOX (GTK_DIALOG (progress_dialog)->vbox), container, FALSE, TRUE, 0); + gtk_box_pack_start ( + GTK_BOX (content_area), container, FALSE, TRUE, 0); widget = gtk_image_new_from_stock (GTK_STOCK_COPY, GTK_ICON_SIZE_DIALOG); gtk_misc_set_alignment (GTK_MISC (widget), 0.0, 0.0); diff --git a/plugins/bbdb/bbdb.c b/plugins/bbdb/bbdb.c index aa11e71f3d..545fd6842d 100644 --- a/plugins/bbdb/bbdb.c +++ b/plugins/bbdb/bbdb.c @@ -681,7 +681,7 @@ bbdb_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data) /* Create a new notebook page */ page = gtk_vbox_new (FALSE, 0); - GTK_CONTAINER (page)->border_width = 12; + gtk_container_set_border_width (GTK_CONTAINER (page), 12); tab_label = gtk_label_new (_("Automatic Contacts")); gtk_notebook_append_page (GTK_NOTEBOOK (hook_data->parent), page, tab_label); @@ -694,7 +694,7 @@ bbdb_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data) str = g_strdup_printf ("<span weight=\"bold\">%s</span>", _("Automatic Contacts")); gtk_label_set_markup (GTK_LABEL (frame_label), str); g_free (str); - GTK_MISC (frame_label)->xalign = 0.0; + gtk_misc_set_alignment (GTK_MISC (frame_label), 0.0, 0.5); gtk_box_pack_start (GTK_BOX (frame), frame_label, FALSE, FALSE, 0); /* Indent/padding */ @@ -730,7 +730,7 @@ bbdb_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data) str = g_strdup_printf ("<span weight=\"bold\">%s</span>", _("Instant Messaging Contacts")); gtk_label_set_markup (GTK_LABEL (frame_label), str); g_free (str); - GTK_MISC (frame_label)->xalign = 0.0; + gtk_misc_set_alignment (GTK_MISC (frame_label), 0.0, 0.5); gtk_box_pack_start (GTK_BOX (frame), frame_label, FALSE, FALSE, 0); /* Indent/padding */ diff --git a/plugins/calendar-weather/calendar-weather.c b/plugins/calendar-weather/calendar-weather.c index 50c698da28..b33141a980 100644 --- a/plugins/calendar-weather/calendar-weather.c +++ b/plugins/calendar-weather/calendar-weather.c @@ -208,6 +208,7 @@ static GtkDialog * create_source_selector (ESource *source) { GtkWidget *dialog, *treeview, *scrolledwindow; + GtkWidget *content_area; GtkCellRenderer *text; GtkTreeSelection *selection; gchar *uri_text; @@ -256,9 +257,10 @@ create_source_selector (ESource *source) text = gtk_cell_renderer_text_new (); gtk_tree_view_insert_column_with_attributes (GTK_TREE_VIEW (treeview), -1, "location", text, "text", 0, NULL); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), scrolledwindow); + content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); + gtk_container_add (GTK_CONTAINER (content_area), scrolledwindow); gtk_container_set_border_width (GTK_CONTAINER (scrolledwindow), 6); - gtk_box_set_spacing (GTK_BOX (GTK_DIALOG (dialog)->vbox), 6); + gtk_box_set_spacing (GTK_BOX (content_area), 6); gtk_dialog_set_response_sensitive (GTK_DIALOG (dialog), GTK_RESPONSE_OK, FALSE); gtk_window_set_default_size (GTK_WINDOW (dialog), 420, 340); diff --git a/plugins/email-custom-header/email-custom-header.c b/plugins/email-custom-header/email-custom-header.c index 84452b28a9..771b23874f 100644 --- a/plugins/email-custom-header/email-custom-header.c +++ b/plugins/email-custom-header/email-custom-header.c @@ -534,8 +534,9 @@ destroy_compo_data (gpointer data) static void action_email_custom_header_cb (GtkAction *action, EMsgComposer *composer) { - GtkUIManager *ui_manager; - GtkWidget *menuitem; + GtkUIManager *ui_manager; + GtkWidget *menuitem; + GdkWindow *window; CustomHeaderOptionsDialog *dialog = NULL; EmailCustomHeaderWindow *new_email_custom_header_window = NULL; @@ -544,14 +545,15 @@ static void action_email_custom_header_cb (GtkAction *action, EMsgComposer *comp new_email_custom_header_window = g_object_get_data ((GObject *) composer, "compowindow"); - if (epech_check_existing_composer_window(new_email_custom_header_window,menuitem->window) == 0) { + window = gtk_widget_get_window (menuitem); + if (epech_check_existing_composer_window(new_email_custom_header_window,window) == 0) { dialog = new_email_custom_header_window->epech_dialog; } else { dialog = epech_dialog_new (); if (dialog) { EmailCustomHeaderWindow *new_email_custom_header_window; new_email_custom_header_window = g_new0(EmailCustomHeaderWindow, 1); - new_email_custom_header_window->epech_window = menuitem->window; + new_email_custom_header_window->epech_window = window; new_email_custom_header_window->epech_dialog = dialog; g_object_set_data_full ((GObject *) composer, "compowindow", new_email_custom_header_window, destroy_compo_data); } diff --git a/plugins/groupwise-features/junk-mail-settings.c b/plugins/groupwise-features/junk-mail-settings.c index b868e28c5a..192b4f2b0d 100644 --- a/plugins/groupwise-features/junk-mail-settings.c +++ b/plugins/groupwise-features/junk-mail-settings.c @@ -62,6 +62,7 @@ void gw_junk_mail_settings_cb (GtkAction *action, EShellView *shell_view) { GtkWidget *dialog ,*w, *notebook, *box; + GtkWidget *content_area; JunkSettings *junk_tab; gint page_count =0; EGwConnection *cnc; @@ -86,9 +87,10 @@ gw_junk_mail_settings_cb (GtkAction *action, EShellView *shell_view) GTK_STOCK_OK, GTK_RESPONSE_ACCEPT, NULL); + content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); gtk_window_set_default_size ((GtkWindow *) dialog, 292, 260); gtk_widget_ensure_style (dialog); - gtk_container_set_border_width ((GtkContainer *) ((GtkDialog *) dialog)->vbox, 12); + gtk_container_set_border_width (GTK_CONTAINER (content_area), 12); box = gtk_vbox_new (FALSE, 6); w = gtk_label_new (""); msg = g_strdup_printf("<b>%s</b>", _("Junk Mail Settings")); @@ -105,12 +107,12 @@ gw_junk_mail_settings_cb (GtkAction *action, EShellView *shell_view) notebook = gtk_notebook_new (); gtk_notebook_append_page ((GtkNotebook *)notebook, box, NULL); gtk_box_pack_start ( - (GtkBox *) ((GtkDialog *) dialog)->vbox, - notebook, TRUE, TRUE, 0); + GTK_BOX (content_area), notebook, TRUE, TRUE, 0); } if (page_count == 0) - gtk_box_pack_start ((GtkBox *) ((GtkDialog *) dialog)->vbox, box, TRUE, TRUE, 0); + gtk_box_pack_start ( + GTK_BOX (content_area), box, TRUE, TRUE, 0); g_signal_connect (dialog, "response", G_CALLBACK (junk_dialog_response), junk_tab); gtk_widget_show_all (dialog); diff --git a/plugins/groupwise-features/mail-retract.c b/plugins/groupwise-features/mail-retract.c index 17d5c7a554..69b9acd5f0 100644 --- a/plugins/groupwise-features/mail-retract.c +++ b/plugins/groupwise-features/mail-retract.c @@ -66,6 +66,7 @@ gw_retract_mail_cb (GtkAction *action, EShellView *shell_view) CamelStore *store; gchar *id = NULL; GtkWidget *confirm_dialog, *confirm_warning; + GtkWidget *content_area; gint n; g_return_if_fail (get_selected_info (shell_view, &folder, &id)); @@ -76,16 +77,21 @@ gw_retract_mail_cb (GtkAction *action, EShellView *shell_view) cnc = get_cnc (store); if (cnc && E_IS_GW_CONNECTION(cnc)) { - confirm_dialog = gtk_dialog_new_with_buttons (_("Message Retract"), GTK_WINDOW (e_shell_view_get_shell_window (shell_view)), - GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT, - GTK_STOCK_YES, GTK_RESPONSE_YES, - GTK_STOCK_NO, GTK_RESPONSE_NO, NULL); + confirm_dialog = gtk_dialog_new_with_buttons ( + _("Message Retract"), + GTK_WINDOW (e_shell_view_get_shell_window (shell_view)), + GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT, + GTK_STOCK_YES, GTK_RESPONSE_YES, + GTK_STOCK_NO, GTK_RESPONSE_NO, NULL); + + content_area = gtk_dialog_get_content_area ( + GTK_DIALOG (confirm_dialog)); confirm_warning = gtk_label_new (_("Retracting a message may remove it from the recipient's mailbox. Are you sure you want to do this?")); gtk_label_set_line_wrap (GTK_LABEL (confirm_warning), TRUE); gtk_label_set_selectable (GTK_LABEL (confirm_warning), TRUE); - gtk_container_add (GTK_CONTAINER ((GTK_DIALOG(confirm_dialog))->vbox), confirm_warning); + gtk_container_add (GTK_CONTAINER (content_area), confirm_warning); gtk_widget_set_size_request (confirm_dialog, 400, 100); gtk_widget_show_all (confirm_dialog); diff --git a/plugins/groupwise-features/share-folder-common.c b/plugins/groupwise-features/share-folder-common.c index 41dde5a9f9..e7775b216a 100644 --- a/plugins/groupwise-features/share-folder-common.c +++ b/plugins/groupwise-features/share-folder-common.c @@ -286,6 +286,7 @@ static void new_folder_response (EMFolderSelector *emfs, gint response, EMFolderTreeModel *model) { GtkWidget *users_dialog; + GtkWidget *content_area; GtkWidget *w; struct ShareInfo *ssi; const gchar *uri; @@ -312,12 +313,13 @@ new_folder_response (EMFolderSelector *emfs, gint response, EMFolderTreeModel *m _("Users"), NULL, GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_NO_SEPARATOR, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,GTK_STOCK_OK, GTK_RESPONSE_OK, NULL); w = gtk_label_new_with_mnemonic (_("Enter the users and set permissions")); gtk_widget_show(w); - gtk_box_pack_start(GTK_BOX (GTK_DIALOG (users_dialog)->vbox), (GtkWidget *) w, TRUE, TRUE, 6); + content_area = gtk_dialog_get_content_area (GTK_DIALOG (users_dialog)); + gtk_box_pack_start(GTK_BOX (content_area), (GtkWidget *) w, TRUE, TRUE, 6); ssi->sf = share_folder_new (cnc, NULL); gtk_widget_set_sensitive (GTK_WIDGET ((ssi->sf)->table), TRUE); ssi->model = model; ssi->emfs = emfs; - gtk_widget_reparent (GTK_WIDGET ((ssi->sf)->table), GTK_DIALOG (users_dialog)->vbox); + gtk_widget_reparent (GTK_WIDGET ((ssi->sf)->table), content_area); gtk_widget_hide((GtkWidget*) emfs); gtk_window_resize (GTK_WINDOW (users_dialog), 350, 300); gtk_widget_show(users_dialog); diff --git a/plugins/groupwise-features/status-track.c b/plugins/groupwise-features/status-track.c index 40fbd0b562..0243e1e453 100644 --- a/plugins/groupwise-features/status-track.c +++ b/plugins/groupwise-features/status-track.c @@ -94,6 +94,7 @@ gw_track_message_status_cb (GtkAction *action, GtkDialog *d; GtkTable *table; GtkWidget *widget; + GtkWidget *content_area; GtkScrolledWindow *win; GtkVBox *vbox; @@ -117,12 +118,13 @@ gw_track_message_status_cb (GtkAction *action, /* Create the dialog */ d = (GtkDialog *) gtk_dialog_new (); + content_area = gtk_dialog_get_content_area (d); gtk_dialog_add_button (d, GTK_STOCK_OK, GTK_RESPONSE_OK); gtk_window_set_title (GTK_WINDOW (d), _("Message Status")); table = (GtkTable *) gtk_table_new (1, 2, FALSE); win = (GtkScrolledWindow *) gtk_scrolled_window_new (NULL, NULL); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG(d)->vbox), GTK_WIDGET (win)); + gtk_container_add (GTK_CONTAINER (content_area), GTK_WIDGET (win)); vbox = (GtkVBox *) gtk_vbox_new (FALSE, 12); gtk_scrolled_window_add_with_viewport (win, GTK_WIDGET(vbox)); gtk_box_pack_start (GTK_BOX (vbox), GTK_WIDGET (table), FALSE, TRUE, 0); diff --git a/plugins/image-inline/image-inline.c b/plugins/image-inline/image-inline.c index 648abc02dd..861aaacfef 100644 --- a/plugins/image-inline/image-inline.c +++ b/plugins/image-inline/image-inline.c @@ -232,6 +232,7 @@ size_allocate_cb (GtkHTMLEmbedded *embedded, GtkAllocation *allocation, ImageInlinePObject *image_object) { + GtkAllocation image_allocation; GtkWidget *widget; gint pixbuf_width; gint pixbuf_height; @@ -240,7 +241,8 @@ size_allocate_cb (GtkHTMLEmbedded *embedded, gdouble zoom = 1.0; widget = GTK_WIDGET (image_object->object.format->html); - widget_width = widget->allocation.width - 12; + gtk_widget_get_allocation (widget, &image_allocation); + widget_width = image_allocation.width - 12; pixbuf_width = gdk_pixbuf_get_width (image_object->pixbuf); pixbuf_height = gdk_pixbuf_get_height (image_object->pixbuf); diff --git a/plugins/itip-formatter/itip-formatter.c b/plugins/itip-formatter/itip-formatter.c index 9f9b3a507b..ddec723c99 100644 --- a/plugins/itip-formatter/itip-formatter.c +++ b/plugins/itip-formatter/itip-formatter.c @@ -2642,7 +2642,7 @@ itip_formatter_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data) /* Create a new notebook page */ page = gtk_vbox_new (FALSE, 0); - GTK_CONTAINER (page)->border_width = 12; + gtk_container_set_border_width (GTK_CONTAINER (page), 12); tab_label = gtk_label_new (_("Calendar and Tasks")); gtk_notebook_append_page (GTK_NOTEBOOK (hook_data->parent), page, tab_label); @@ -2655,7 +2655,7 @@ itip_formatter_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data) str = g_strdup_printf ("<span weight=\"bold\">%s</span>", _("General")); gtk_label_set_markup (GTK_LABEL (frame_label), str); g_free (str); - GTK_MISC (frame_label)->xalign = 0.0; + gtk_misc_set_alignment (GTK_MISC (frame_label), 0.0, 0.5); gtk_box_pack_start (GTK_BOX (frame), frame_label, FALSE, FALSE, 0); /* Indent/padding */ @@ -2681,7 +2681,7 @@ itip_formatter_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data) str = g_strdup_printf ("<span weight=\"bold\">%s</span>", _("Conflict Search")); gtk_label_set_markup (GTK_LABEL (frame_label), str); g_free (str); - GTK_MISC (frame_label)->xalign = 0.0; + gtk_misc_set_alignment (GTK_MISC (frame_label), 0.0, 0.5); gtk_box_pack_start (GTK_BOX (frame), frame_label, FALSE, FALSE, 0); /* Indent/padding */ diff --git a/plugins/itip-formatter/itip-view.c b/plugins/itip-formatter/itip-view.c index 83d314685e..bf40055d1e 100644 --- a/plugins/itip-formatter/itip-view.c +++ b/plugins/itip-formatter/itip-view.c @@ -966,11 +966,7 @@ alarm_check_toggled_cb (GtkWidget *check1, GtkWidget *check2) g_return_if_fail (check1 != NULL); g_return_if_fail (check2 != NULL); -#if GTK_CHECK_VERSION(2,19,7) gtk_widget_set_sensitive (check2, !(gtk_widget_get_visible (check1) && gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (check1)))); -#else - gtk_widget_set_sensitive (check2, !(GTK_WIDGET_VISIBLE (check1) && gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (check1)))); -#endif } static void diff --git a/plugins/mail-notification/mail-notification.c b/plugins/mail-notification/mail-notification.c index 2b0d768098..9503aaf27a 100644 --- a/plugins/mail-notification/mail-notification.c +++ b/plugins/mail-notification/mail-notification.c @@ -333,6 +333,7 @@ static void do_properties (GtkMenuItem *item, gpointer user_data) { GtkWidget *cfg, *dialog, *vbox, *label, *hbox; + GtkWidget *content_area; gchar *text; cfg = get_cfg_widget (); @@ -367,8 +368,10 @@ do_properties (GtkMenuItem *item, gpointer user_data) GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, NULL); + content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); + gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), vbox); + gtk_container_add (GTK_CONTAINER (content_area), vbox); gtk_container_set_border_width (GTK_CONTAINER (vbox), 10); gtk_widget_set_size_request (dialog, 400, -1); g_signal_connect_swapped ( diff --git a/plugins/mark-all-read/mark-all-read.c b/plugins/mark-all-read/mark-all-read.c index 756ced9766..44ec323cf1 100644 --- a/plugins/mark-all-read/mark-all-read.c +++ b/plugins/mark-all-read/mark-all-read.c @@ -83,14 +83,15 @@ prompt_user (void) gint response; dialog = gtk_dialog_new (); - gtk_widget_hide (GTK_DIALOG (dialog)->action_area); + widget = gtk_dialog_get_action_area (GTK_DIALOG (dialog)); + gtk_widget_hide (widget); gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE); gtk_window_set_title (GTK_WINDOW (dialog), ""); g_signal_connect ( dialog, "map", G_CALLBACK (gtk_widget_queue_resize), NULL); gtk_container_set_border_width (GTK_CONTAINER (dialog), 12); - vbox = GTK_DIALOG (dialog)->vbox; + vbox = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); /* Table */ widget = gtk_table_new (3, 2, FALSE); diff --git a/plugins/publish-calendar/url-editor-dialog.c b/plugins/publish-calendar/url-editor-dialog.c index 37910d8f47..1211726b4b 100644 --- a/plugins/publish-calendar/url-editor-dialog.c +++ b/plugins/publish-calendar/url-editor-dialog.c @@ -116,11 +116,7 @@ check_input (UrlEditorDialog *dialog) gtk_widget_hide (dialog->fb_duration_combo); } -#if GTK_CHECK_VERSION(2,19,7) if (gtk_widget_get_sensitive (dialog->events_selector)) { -#else - if (GTK_WIDGET_IS_SENSITIVE (dialog->events_selector)) { -#endif sources = e_source_selector_get_selection (E_SOURCE_SELECTOR (dialog->events_selector)); n += g_slist_length (sources); } @@ -332,6 +328,7 @@ static gboolean url_editor_dialog_construct (UrlEditorDialog *dialog) { GtkWidget *toplevel; + GtkWidget *content_area; GConfClient *gconf; GtkSizeGroup *group; EPublishUri *uri; @@ -376,8 +373,9 @@ url_editor_dialog_construct (UrlEditorDialog *dialog) uri = dialog->uri; + content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); toplevel = e_builder_get_widget (dialog->builder, "publishing toplevel"); - gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox), toplevel); + gtk_container_add (GTK_CONTAINER (content_area), toplevel); gtk_container_set_border_width (GTK_CONTAINER (dialog), 6); gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE); diff --git a/plugins/startup-wizard/startup-wizard.c b/plugins/startup-wizard/startup-wizard.c index a38b2d9e9a..fc012eaf7b 100644 --- a/plugins/startup-wizard/startup-wizard.c +++ b/plugins/startup-wizard/startup-wizard.c @@ -228,6 +228,7 @@ startup_wizard_commit (EPlugin *ep, EMConfigTargetAccount *target) { EShell *shell; EShellSettings *shell_settings; + GtkWidget *content_area; gchar *location; shell = e_shell_get_default (); @@ -245,15 +246,27 @@ startup_wizard_commit (EPlugin *ep, EMConfigTargetAccount *target) import_iterator = import_importers; import_importer = import_iterator->data; - import_dialog = e_alert_dialog_new_for_args (e_shell_get_active_window (shell), "shell:importing", _("Importing data."), NULL); - g_signal_connect(import_dialog, "response", G_CALLBACK(import_dialog_response), NULL); + import_dialog = e_alert_dialog_new_for_args ( + e_shell_get_active_window (shell), + "shell:importing", _("Importing data."), NULL); + content_area = gtk_dialog_get_content_area ( + GTK_DIALOG (import_dialog)); + g_signal_connect ( + import_dialog, "response", + G_CALLBACK (import_dialog_response), NULL); import_label = gtk_label_new(_("Please wait")); import_progress = gtk_progress_bar_new(); - gtk_box_pack_start(GTK_BOX(((GtkDialog *)import_dialog)->vbox), import_label, FALSE, FALSE, 0); - gtk_box_pack_start(GTK_BOX(((GtkDialog *)import_dialog)->vbox), import_progress, FALSE, FALSE, 0); + gtk_box_pack_start ( + GTK_BOX (content_area), + import_label, FALSE, FALSE, 0); + gtk_box_pack_start ( + GTK_BOX (content_area), + import_progress, FALSE, FALSE, 0); gtk_widget_show_all(import_dialog); - e_import_import(import, (EImportTarget *)import_target, import_importer, import_status, import_done, NULL); + e_import_import ( + import, (EImportTarget *) import_target, + import_importer, import_status, import_done, NULL); } else { gtk_main_quit(); } |