summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2018-05-13 02:09:36 +0200
committerlukefromdc <[email protected]>2018-05-18 14:03:16 -0400
commit6841bd73832a0f2373f38c3a99e341a9bcdc5db4 (patch)
tree8bd313d4635f64d13f705dcd09f09bb0def189bf
parentc31de771e227f69911b3666029a62aa1f70bf910 (diff)
downloadcaja-6841bd73832a0f2373f38c3a99e341a9bcdc5db4.tar.bz2
caja-6841bd73832a0f2373f38c3a99e341a9bcdc5db4.tar.xz
avoid deprecated 'gtk_dialog_get_action_area'
-rw-r--r--libcaja-private/caja-autorun.c11
-rw-r--r--src/file-manager/fm-properties-window.c11
2 files changed, 12 insertions, 10 deletions
diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c
index 23a153dd..e60fe8a6 100644
--- a/libcaja-private/caja-autorun.c
+++ b/libcaja-private/caja-autorun.c
@@ -943,6 +943,7 @@ do_autorun_for_content_type (GMount *mount, const char *x_content_type, CajaAuto
GtkWidget *always_check_button;
GtkWidget *eject_button;
GtkWidget *image;
+ GtkWidget *action_area;
char *markup;
char *content_description;
char *mount_name;
@@ -1150,10 +1151,10 @@ show_dialog:
"process-stop",
GTK_RESPONSE_CANCEL);
- eel_dialog_add_button (GTK_DIALOG (dialog),
- _("_OK"),
- "gtk-ok",
- GTK_RESPONSE_OK);
+ action_area = gtk_widget_get_parent (eel_dialog_add_button (GTK_DIALOG (dialog),
+ _("_OK"),
+ "gtk-ok",
+ GTK_RESPONSE_OK));
gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK);
@@ -1179,7 +1180,7 @@ show_dialog:
data->should_eject = FALSE;
}
gtk_dialog_add_action_widget (GTK_DIALOG (dialog), eject_button, AUTORUN_DIALOG_RESPONSE_EJECT);
- gtk_button_box_set_child_secondary (GTK_BUTTON_BOX (gtk_dialog_get_action_area (GTK_DIALOG (dialog))), eject_button, TRUE);
+ gtk_button_box_set_child_secondary (GTK_BUTTON_BOX (action_area), eject_button, TRUE);
/* show the dialog */
gtk_widget_show_all (dialog);
diff --git a/src/file-manager/fm-properties-window.c b/src/file-manager/fm-properties-window.c
index 3476aa50..d5f7b4eb 100644
--- a/src/file-manager/fm-properties-window.c
+++ b/src/file-manager/fm-properties-window.c
@@ -5079,6 +5079,7 @@ create_properties_window (StartupData *startup_data)
{
FMPropertiesWindow *window;
GList *l;
+ GtkWidget *action_area;
window = FM_PROPERTIES_WINDOW (gtk_widget_new (fm_properties_window_get_type (), NULL));
@@ -5177,14 +5178,14 @@ create_properties_window (StartupData *startup_data)
"help-browser",
GTK_RESPONSE_HELP);
- eel_dialog_add_button (GTK_DIALOG (window),
- _("_Close"),
- "window-close",
- GTK_RESPONSE_CLOSE);
+ action_area = gtk_widget_get_parent (eel_dialog_add_button (GTK_DIALOG (window),
+ _("_Close"),
+ "window-close",
+ GTK_RESPONSE_CLOSE));
/* FIXME - HIGificiation, should be done inside GTK+ */
gtk_container_set_border_width (GTK_CONTAINER (gtk_dialog_get_content_area (GTK_DIALOG (window))), 12);
- gtk_container_set_border_width (GTK_CONTAINER (gtk_dialog_get_action_area (GTK_DIALOG (window))), 0);
+ gtk_container_set_border_width (GTK_CONTAINER (action_area), 0);
gtk_box_set_spacing (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (window))), 12);
/* Update from initial state */